Using the Send User Message (SNDUSRMSG) command,
you can send an inquiry message or an informational message to a display station
user, the system operator, or a user-defined message queue.
If you use the Send User Message (SNDUSRMSG) command
to send an inquiry message to the user, the procedure or program waits for
a response from the user. The message can be either an immediate message or
a predefined message. For an interactive job, the message is sent to the
display station operator by default. For a batch job, the message is sent
to the system operator by default. To send a message from a procedure or program
using the Send User Message (SNDUSRMSG) command, you can
specify the following on the Send User Message (SNDUSRMSG) command:
- Message identifier or an immediate message. The message identifier is
the name of the message description for a predefined message.
- Message file. The name of the message file containing the message description
when a predefined message is sent.
- Message data fields. If a predefined message is sent, these fields contain
the value for the substitution variables in the message. The format of each
field must be described in the message description. If an immediate message
is sent, there are no message data fields.
- Valid replies to an inquiry message.
- Default reply value to an inquiry message.
- Message type.
- Message queue to which the message is to be sent.
- Message reply. A CL variable, if any, that is to contain the reply received
in response to an inquiry message.
- Translation table. The translation table to be used, if any, to translate
the reply value. This is normally used for translating lowercase to uppercase.
- Coded character set identifier (CCSID). Specifies the coded character
set identifier (CCSID) that the supplied message or message data is in.