Hi I declared a native method

public native void defineBridgeMethod(ModelHandler modh) /*-{
          $wnd.computeLoanInterest = function(amt) {
 
mo...@com.dhc.dhcvision.ui.client.modelhandler::computeLoanInterest(I)
(amt);
          }
       }-*/;

and build in in my application by calling

ModelHandler modH = new ModelHandler();
defineBridgeMethod(modh);

ModelHandler class looks like this:

public class ModelHandler {
    public void computeLoanInterest(int amt) {
        MessageBox.alert(String.valueOf(amt) + "inner");
    }
}

I call the native method in html javascript like that:
parent.computeLoanInterest(5);


The first time I called the native method from javascriptside
everything works fine but now after a while I always get an error
message "Object doesn't support this property or method". It seems
that the mentioned 'object' is the ModelHandler instance because the
javascript error is pointed to line 2 which is position of the call of
the ModelHandler instance in the native method declaration.
Any idea why it works in the beginning and what could happened that it
does not work anymore? I always test these stuff in Hosted Mode.

Thx.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to