Hi Isomorphic,
I'm using current SmartGWT 5.1 and would like to exchange the default error message for "http 0".
I have users with a weak connection and they keep thinking my application is down and notice that it is actually their connection only when they try to open google etc.
I'd like to replace the very technical error message
I read the error handling docs and the RPCManager docs.
Using setHandleTransportErrorCallback() with SC.warn(myMessage) as only action does not solve the problem.
The code is executed (breakpoint is hit), but the same message is displayed. I think this is because this:
The handleError() is called as well and does it's SC.say(). Displaying two SC.say() usually does not work, so I think this is what is happening.
What I would like to do is a
but there is no such super().
I also tried to find the default handleError-implementation which does
in the modules-debug, but did not succeed.
What is your suggestion to solve this case?
Thank you & Best regards
Blama
I'm using current SmartGWT 5.1 and would like to exchange the default error message for "http 0".
I have users with a weak connection and they keep thinking my application is down and notice that it is actually their connection only when they try to open google etc.
I'd like to replace the very technical error message
I read the error handling docs and the RPCManager docs.
Using setHandleTransportErrorCallback() with SC.warn(myMessage) as only action does not solve the problem.
The code is executed (breakpoint is hit), but the same message is displayed. I think this is because this:
The default implementation takes no action - by default transport errors are handled via handleError(), or by the standard request callback methods, depending on request.willHandleError. To perform custom handing for transport errors this classMethod may be overridden as follows
What I would like to do is a
Code:
if (httpCode = 0) SC.say(myMessage); else super();
I also tried to find the default handleError-implementation which does
By default handleError() always logs a warning. In addition, if response.data was set to a String, a warning dialog will be shown to the user with response.data as the message, which allows the server to send user error messages back without writing custom client-side error handling.
What is your suggestion to solve this case?
Thank you & Best regards
Blama
Comment