Please remember this is a work in progress. Home » Classes

Classes

 

TIWExceptionRenderer

 

This class is responsible for rendering the HTML that will be returned to the browser when an unhandled exception occurs within your application (Server error 500). It loads and processes IntraWeb's standard error template. It is also used to display session timeout exceptions to the user.

Unhandled exceptions also contain the application stack trace, when available, and most informations generated by the TIWExceptionLogger class. When the request is local (originated from localhost), the standard error page contains all information generated by TIWExceptionLogger, otherwise only a subset of the information is rendered.

This class only has class methods and class vars, and should not be instantiated. Users may override it and register this new class using SetExceptionRendererClass.

Unit

IWExceptionRenderer

Class hierarchy

TObject -> TIWExceptionRenderer

Methods

SetColors [Public]

Declaration: class procedure SetColors(HBC1, HBC2, HTC, BBC, BTC: TIWColor);

Description: Set the colors used by the default HTML template, used by IntraWeb, when an unhandled exception occurs.

Parameters:

  • HBC1 (Header Background Color 1): First color (upper pixels) of the header gradient fill
  • HBC2 (Header Background Color 2): Second color (lower pixels) of the header gradient fill
  • HTC (Hader Text Color): Color of the text used in header
  • BBC (Body Background Color): Color of body background
  • BTC (Body Text Color): Color used in body text

RenderHTML [Public]

Declaration: class function RenderHTML(AException: Exception; ARequest: THttpRequest): string; virtual;

Description: Returns the final HTML, used to display error information

Parameters:

  • AException (Exception): The exception object
  • ARequest (THttpRequest): The HTTPRequest received by the application

Result: String containing the final HTML


Public Functions

SetExceptionRendererClass [Public]

Declaration: procedure SetExceptionRendererClass(IWExceptionRendererClass: TIWExceptionRendererClass);

Description: Register a new TIWExceptionRendererClass to be used by the IntraWeb application.

Parameters:

  • IWExceptionRendererClass (TIWExceptionRendererClass): class of TIWExceptionRendererClass to be used by the IntraWeb application

New standard error page

Standard error message page

 

 

Terms of Use | Privacy Statement © 2002 - 2024 Atozed Software