Version 6.3.8 for OpenVMS
 —  Web Technology  —

Generate Error Page

Subroutine Name Executable Example Viewable Example

W3ERROR
W3ERROR-TEMPLATE
W3ERROR-TEMPLATE-XML
W3ERROR-TEXT

E3ERROR

E3ERROR

Description

Errors generated by the Natural runtime should be handled to avoid screen output. Therefore, an ON ERROR section must be added to all programs called with the Natural Web Interface. The PDA W3CONST must be added as well.

The subroutine W3ERROR-TEMPLATE is called if an error occurs. This routine can be changed for your own needs.

The subroutine W3ERROR-TEMPLATE-XML returns the error page as XHTML page. This routine can be changed for your own needs. To activate this template, uncatalog W3ERROR-TEMPLATE and rename the subroutine from W3ERROR-TEMPLATE-XML to W3ERROR-TEMPLATE and stow.

The subroutine W3ERROR-TEXT is for internal use only.

Parameters
1 ##W3ERROR
  2 NR         (I4)   /* i /m : Number of the error
  2 LINE       (I4)   /* i /m : Line in the Natural program
  2 SUBPROGRAM (A008) /* i /m : Subprogram name
  2 SUBROUTINE (A032) /* i /m : Subroutine name
  2 TEXT       (A250) /* i /m : Error text
How To Invoke
ON ERROR
   PERFORM W3ERROR ##W3ERROR
   PERFORM W3END ##RPC
   ESCAPE ROUTINE
END-ERROR

Top of page