Customizing the display of errors

Customizing the display of errors

IntraWeb has several options to customize the display of error messages.


In the templates directory you can specify two files, IWException.html and IWError.html.


IWException.html is used when an exception is raised in your code in a form’s event. However it will only be used if the ServerController.ExceptionDisplayMode is set to a value other than smAlert. smAlert is the default, so unless you change it IWException.html will not be used.


IWError.html is used when the display system is not active and IntraWeb cannot guarantee its ability to display anything except simple HTML. These situations are:

  • Internal IntraWeb errors. These are often caused by:
    • Malformed HTTP requests from hack attempts
    • Bugs
  • Errors during User Session creation – This template is also used if an error occurs during session creation, including user code that is called in events.
  • If you have used an option such as tmCookie and the browser or device does not support cookies and ServerController.NoCookieSupport has not been specified.
  • If an unknown browser is detected and ServerController.UnknownBrowser has notbeen specified.
  • For HTML 3.2 and WAP: If an unknown device is detected and ServerController.DeviceNotSupported has notbeen specified.