Skip to main content

DSPPGMMSGH - UNVVTSND configuration option

Defines handlers for Display Program Messages scenarios that may occur on the current Virtual terminal screen.

During an invocation of UNVVTSND, after the specified key press is performed, the resulting screen is checked for “Display Program Messages” with a message needing a reply. If the screen is determined to be in this state, the defined handlers are evaluated, and the best matched handler is performed.

Up to 10 handlers can be defined.

UNVVTSND Parameter: DSPPGMMSGH( [(action message_pattern reply_or_goto_label maximum_replies)]... )

  • action - Specifies the action to take when this handler is chosen. Valid options are:
    • *none - No action is taken by the handler.
    • *rpy - The specified reply is sent to the message.
    • *abort - The UNVVTSND command instance will end without further processing. In addition, if UNVVTSND is being executed in the context of a UNVVT script, the UNVVT script execution will terminate with a severity of 99.
    • *goto - No action is taken within the virtual terminal session. However, if UNVVTSND is being executed within the context of a UNVVT script execution, script execution will proceed to the specified label. If the specified label is not found within the UNVVT script, a processing error will occur and the UNVVT command execution will terminate with a severity of 99.
    • *wsmsg - No action is taken within the virtual terminal session. A diagnostic message is issued within the job environment under which UNVVTSND is executing, indicating that the virtual terminal session is waiting for a message response, as detected by message handler n (where n is the 1 based index of the UNVVTSND handler that was triggered).
  • message_pattern - Specifies a patten to compare with the message associated with the “Display Program Message” message.
  • reply_or_goto_label - If the action is specified as *RPY, this field specifies the reply to send to the message. If the action is specified as *GOTO, this field specifies the label a UNVVT script where execution should resume following the completion of the UNVVTSND command instance.
  • maximum_replies - Specifies the maximum number of times a handler can be selected in a single instance of UNVVTSND. Once the limit is reached, the handler is deactivated (for the current instance of UNVVTSND), allowing another handler to be chosen. Valid values are none (field is left blank) or 1-999.