CL Programming

Example of Describing a Message

In the following example, the ADDMSGD command creates a message to be used in applications such as order entry. The message is issued when a customer number entered on the display is not found. The message is:

   Customer number &1 not found

The ADDMSGD command for this message is:

ADDMSGD   MSGID(USR4310) +
          MSGF(QGPL/USRMSG)  +
          MSG('Customer number &1 not found') +
          SECLVL('Change customer number') +
          SEV(40) +
          FMT((*CHAR 8))

The message is added to the USRMSG file in the library QGPL.

You can use the DSPMSGD or WRKMSGD command to print or display message descriptions.

The SECLVL parameter provides very simple text. To make this appear on the Additional Message Information display, you specify SECLVL('message text'). The text you specify on this parameter appears on the Additional Message Information display when you press the Help key after placing the cursor on this message.


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]