Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    self.getValue is not a function

    Hi,

    Using the following code I've got a strange exception :
    Code:
    ButtonItem btSendDocument = new ButtonItem("Envoyer");
    btSendDocument.addClickHandler(new com.smartgwt.client.widgets.form.fields.events.ClickHandler() {  
           public void onClick(com.smartgwt.client.widgets.form.fields.events.ClickEvent event) {
              	FormItem fi[] = form.getFields();
                    	String toDisplay = "";
    	            	for (FormItem aFI : fi) {
    	            		toDisplay += aFI.getName() + " : ";
    	            		toDisplay += aFI.getValue().toString() + "\n";
    	            	}
            	Window.alert(toDisplay);
    		            	  
                 }  
          });  	
        	  		  form.addItems(btSendDocument);
    Code:
    Uncaught exception escaped : com.google.gwt.core.client.JavaScriptException
    (TypeError): self.getValue is not a function
     fileName: http://127.0.0.1:8888
     lineNumber: 718
     stack: ()@http://127.0.0.1:8888:718
    @:0
    ([object GWTJavaObject],4128798,[object GWTJavaObject])@http://127.0.0.1:8888/helloworld/hosted.html?helloworld:56
    Is it a bug ?

    Regards,
    Denis.

    #2
    Is your form databound or not? Post the code where you create your form.

    Comment

    Working...
    X