开发者

Error calling method on NPObject when calling Java Applet Method from GWT Client code

I receive this error when calling a Java Applet method from GWT JavaScript client code.

The really strange thing is, this error only occurs when I create a certain object in the said applet method. Specifically, I have a class I created in the GWT "shared" folder, which serializes a class into a JSON string from an instance of this class within the client javascript. The Java applet also instanciates this class in java space, within the said method. When I don't attempt to instanciate this class within the applet method, it runs and retu开发者_JAVA技巧rns no problem. Shouldn't the java instanciation be totally independant of GWT? Also, I wonder why i'm not getting a stack trace in my java console if this exception is occurring within java.

Not sure if this is relevant, but I'm using the GWTAI project for Applet->JavaScript callbacks

TIA for any responses,

Phaedrus

02:40:22.848 [ERROR] [u] Uncaught exception escaped com.google.gwt.core.client.JavaScriptException: (Error): Error calling method on NPObject. stack: Error: Error calling method on NPObject. at [object Object]. (unknown source) at __gwt_jsInvoke (http://127.0.0.1:8888/u/hosted.html?u:76:35)


I don't know if you've come to a solution on that one but bear in mind that GWT plugin in Chrome returns that kind of errors running the debug mode IF the object you're trying to deserialize/"javascript-ify" is too big. Apparently it has to do with some kind of stack size somehow...

I've noticed that it works great on Safari for mac and of course when code is compiled... how annoying! I'm testing everything on a mac safari now since it's the only webkit-based plugin we have at the moment.

Hope that helps and good luck!


To solve this issue, I'll give you the following solution. This worked for me.

Go to Chrome's "Settings" and then choose "Extensions" or you can use the follow url link to access Extensions directly "chrome://extensions/" . There deselect "Developer Mode".

My version of Chrome is 34.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜