U@PRINTERRMSG

The U@PRINTERRMSG routine is used to retrieve and print an error message for errors associated with program parameter information. Before entry, the caller sets the inputs in CRTWS. The error message (E@ERRORMSG), as built, is left in CRTWS after printing and displaying.

Module BATCHERR
Input

E@PGMCODE

E@ERRORCAT

If you do not explicitly set the error category, the API assumes that the error category is the same as the program code.

E@ERRORNBR

E@ERRORVARS

Output

E@ERRORMSG (expanded message)

E@ERRORCAT (reset)

E@ERRORVARS (reset)

Programming Example

*    Set error message for program error display.
     IF        F1@CLLCTN = *BLANKS
               AND F1@ACTVGR = *BLANKS
     EVAL      E@ERRORNBR     = 105
     CALLP     U@PRINTERRMSG                  Print Error Msg