Announcement
Collapse
No announcement yet.
X
-
If you're looking for the general ability to have JavaScript code in your app, that's a core function of GwT, Google "GWT JSNI".
-
Originally posted by smartgwt.devYou should be using Window.Location.getHref() for this.
com.google.gwt.user.client.Window
not:
com.smartgwt.client.widgets.Window
However I'm still not sure how to return a value from JSOHelper.eval()... very hard to find documentation on this topic.
Leave a comment:
-
JSOHelper.eval return values
I am trying to learn how to get data returned from JSOHelper.eval(). I have the following code:
Code:JavaScriptObject jso = JSOHelper.eval("( window.location.href.indexOf('locale=') > -1)");
Unexpected error has occurred.Something other than a Java object was returned from JSNI method '@com.smartgwt.client.util.JSOHelper::eval(Ljava/lang/String;)': JS value of type boolean, expected java.lang.Object
I know it's a boolean.... how do I get it back into my smartgwt code to use?Last edited by bootz15; 21 Jun 2011, 06:18.Tags: None
Leave a comment: