PDA

View Full Version : JavaScript Native Interface (JSNI) get the the HTML component reference



clavinovahan
14 Dec 2010, 2:19 PM
I have a native javascript function called in GXT java code. In the javascript function, I need to access a HTML component, say <div id = "test" > which I put in the inital GWT application entry page. However it always gives me error say the object "test" not defined.

In the funciton, I just directly call test.soSomethong();

Your input is appreciated.

sven
14 Dec 2010, 5:02 PM
How do you expect this to work? What is "test"? Are you using "test" without defining it first? Please post your code so i can be sure what you do.