From Xojo Documentation


WebSession.JavaScriptError(ErrorMessage as String, UserDetails as String) As Boolean

New in 2011r1

Supported for all project types and targets.

A JavaScript error ErrorMessage occurred. A dialog box is presented and the user can enter the UserDetails into a dialog that appears when the error occurred.


A JavaScript error indicates the web browser and the server app are out of sync. When this happens you should usually record the ErrorMessage and UserDetails and close the Session. Further interaction with the browser is not recommended, but since your app is still running on the server, you can save the results to a file or database.

By default, the framework will also write the ErrorMessage and UserDetails to a text file named Errors.log next to your web application. Returning True will prevent the error from being written to this file.

If the web application cannot create Errors.log, it will silently fail, but when running in Debug mode a message is written to the Messages area: "Could not log to errors.log, IOException."