Hello, dear developers!
I have a simple page: MiniDateRangeItem + a button. When I select range from Yesterday till Tomorrow and press this button, I'm getting an exception.
If I select ANY date using a calendar, not relative date - it works just fine.
1. SmartGWT 2.2(19.11.2010 nightly build) + Mozilla Firefox 3.6.12
3. for a client-side problem, the contents of the Developer Console (see FAQ for usage);
4. if there is a JavaScript error, the stack trace logged in the Developer Console (from Internet Explorer if possible);
5. sample code.
6. Exception in Eclipse, in "Development Mode tab":
Please help. Thanks.
I have a simple page: MiniDateRangeItem + a button. When I select range from Yesterday till Tomorrow and press this button, I'm getting an exception.
If I select ANY date using a calendar, not relative date - it works just fine.
1. SmartGWT 2.2(19.11.2010 nightly build) + Mozilla Firefox 3.6.12
3. for a client-side problem, the contents of the Developer Console (see FAQ for usage);
Code:
03:37:34.708:INFO:Log:initialized 03:37:34.719:WARN:Log:NOTE: Firebug is enabled. Firebug greatly slows the performance of applications that make heavy use of JavaScript. Isomorphic highly recommends Firebug for troubleshooting, but Firebug and other development tools should be disabled when assessing the real-world performance of SmartClient applications. 03:37:35.950:WARN:AutoObserver:Use addInterfaceProperties() to add methods to interface [Class AutoObserver] 03:37:59.403:INFO:Log:isc.Page is loaded
Code:
Uncaught exception escaped : com.google.gwt.core.client.JavaScriptException (TypeError): ret.getTime is not a function fileName: http://127.0.0.1:8888 lineNumber: 696 stack: ("fromDate")@http://127.0.0.1:8888:696 @:0 ([object GWTJavaObject],983239,[object GWTJavaObject])@http://127.0.0.1:8888/recondashboard/hosted.html?recondashboard:56 ([object Object],(void 0))@http://127.0.0.1:8888:897 ((function () {var param = {};var event = __gwt_makeJavaInvoke(1)(null, 2883703, param);__gwt_makeJavaInvoke(1)(selfJ, 983239, event);var ret = __gwt_makeJavaInvoke(0)(event, 1114114);return !ret;}),[object Object],[object Object])@http://127.0.0.1:8888:77 @:0 (null,65630,(function () {var param = {};var event = __gwt_makeJavaInvoke(1)(null, 2883703, param);__gwt_makeJavaInvoke(1)(selfJ, 983239, event);var ret = __gwt_makeJavaInvoke(0)(event, 1114114);return !ret;}),[object Object],[object Object])@http://127.0.0.1:8888/recondashboard/hosted.html?recondashboard:56 ([object Object],(void 0))@http://127.0.0.1:8888:27 ([object Object],(void 0))@http://127.0.0.1:8888:13 isc_StatefulCanvas_handleActivate([object Object],(void 0))@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Foundation.js:296 isc_StatefulCanvas_handleClick([object Object],(void 0))@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Foundation.js:298 isc_c_EventHandler_bubbleEvent([object Object],"click")@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Core.js:1493 isc_c_EventHandler_handleClick([object Object])@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Core.js:1343 isc_c_EventHandler__handleMouseUp([object MouseEvent],(void 0))@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Core.js:1330 isc_c_EventHandler_handleMouseUp([object MouseEvent])@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Core.js:1321 isc_c_EventHandler_dispatch(isc_c_EventHandler_handleMouseUp,[object MouseEvent])@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Core.js:1556 anonymous([object MouseEvent])@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Core.js:38 See the Development console log for details. Register a GWT.setUncaughtExceptionHandler(..) for custom uncaught exception handling.
Code:
VLayout mainVL = new VLayout(); final MiniDateRangeItem miniItem = new MiniDateRangeItem("miniitem"); DynamicForm dateForm = new DynamicForm(); dateForm.setItems(miniItem); Button getBtn = new Button("Refresh"); getBtn.addClickHandler(new ClickHandler() { @Override public void onClick(ClickEvent event) { java.util.Date fromDate = miniItem.getFromDate(); java.util.Date toDate = miniItem.getToDate(); } }); HLayout dateRangeHL = new HLayout(); dateRangeHL.setAlign(Alignment.RIGHT); dateRangeHL.setHeight(20); dateRangeHL.addMember(dateForm); dateRangeHL.addMember(getBtn); mainVL.addMember(dateRangeHL); mainVL.setMargin(5); mainVL.setWidth100(); mainVL.setHeight100(); mainVL.draw();
Code:
03:38:26.787 [ERROR] [recondashboard] Uncaught exception escaped com.google.gwt.core.client.JavaScriptException: (TypeError): ret.getTime is not a function fileName: http://127.0.0.1:8888 lineNumber: 696 stack: ("fromDate")@http://127.0.0.1:8888:696 @:0 ([object GWTJavaObject],983239,[object GWTJavaObject])@http://127.0.0.1:8888/recondashboard/hosted.html?recondashboard:56 ([object Object],(void 0))@http://127.0.0.1:8888:897 ((function () {var param = {};var event = __gwt_makeJavaInvoke(1)(null, 2883703, param);__gwt_makeJavaInvoke(1)(selfJ, 983239, event);var ret = __gwt_makeJavaInvoke(0)(event, 1114114);return !ret;}),[object Object],[object Object])@http://127.0.0.1:8888:77 @:0 (null,65630,(function () {var param = {};var event = __gwt_makeJavaInvoke(1)(null, 2883703, param);__gwt_makeJavaInvoke(1)(selfJ, 983239, event);var ret = __gwt_makeJavaInvoke(0)(event, 1114114);return !ret;}),[object Object],[object Object])@http://127.0.0.1:8888/recondashboard/hosted.html?recondashboard:56 ([object Object],(void 0))@http://127.0.0.1:8888:27 ([object Object],(void 0))@http://127.0.0.1:8888:13 isc_StatefulCanvas_handleActivate([object Object],(void 0))@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Foundation.js:296 isc_StatefulCanvas_handleClick([object Object],(void 0))@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Foundation.js:298 isc_c_EventHandler_bubbleEvent([object Object],"click")@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Core.js:1493 isc_c_EventHandler_handleClick([object Object])@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Core.js:1343 isc_c_EventHandler__handleMouseUp([object MouseEvent],(void 0))@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Core.js:1330 isc_c_EventHandler_handleMouseUp([object MouseEvent])@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Core.js:1321 isc_c_EventHandler_dispatch(isc_c_EventHandler_handleMouseUp,[object MouseEvent])@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Core.js:1556 anonymous([object MouseEvent])@http://127.0.0.1:8888/recondashboard/sc/modules/ISC_Core.js:38 at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:237) at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:126) at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:561) at com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:269) at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeObject(JavaScriptHost.java:91) at com.google.gwt.core.client.impl.Impl.apply(Impl.java) at com.google.gwt.core.client.impl.Impl.entry0(Impl.java:214) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103) at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71) at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:157) at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessages(BrowserChannelServer.java:281) at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:531) at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:352) at java.lang.Thread.run(Thread.java:619)
Please help. Thanks.
Comment