Exit Program for General Panel Checking


  Required Parameter Group for Single Parameter Interface:


  QSYSINC Member Name: EUIPGEX

  Required Parameter Group for Multiple Parameter Interface:

  Interface Level 1:

  Interface Level 2:


  QSYSINC Member Name: EUIPGEX

A general exit program may be specified on the USREXIT attribute of the panel definition (PANEL) tag. This attribute specifies the name of a dialog variable identifying the program to call.

The UIM calls the program:

The UIM calls the general exit program and passes information about the function. The exit program performs its task and returns control to the UIM through a normal return or by sending a CPF6A02 or CPF6A03 status message. These messages are transient messages.

If the exit program returns control by sending a CPF6A02 status or escape message, the UIM does not perform the determined function. The panel is redisplayed and any previous messages sent to the UIM are shown.

If the exit program returns control by sending a CPF6A03 status or escape message, the UIM continues performing the determined function. Any previous messages sent to the UIM by the general exit program are shown if and when the function completes. These messages are transient messages.

If the exit program returns control by sending any escape message other than CPF6A02 or CPF6A03, the UIM does not perform the determined function. The panel is redisplayed and any previous messages sent to the UIM are shown. These messages are user messages.

If the exit program returns control normally or sends a non-escape message other than CPF6A02 or CPPF6A03, the UIM continues performing the determined function.

Messages sent to the UIM are displayed only once. They are cleared when the next dialog command is performed, excluding the HELP, PRINT, and PAGEUP or PAGEDOWN (only if paging the message line) dialog commands. If the exit program marks dialog variables in error, the exit program or other application code is responsible for resetting the dialog variables when the variable is no longer incorrect.

The general exit program allows applications to perform extended validity checking on field values. However, other functions are possible because the exit program has access to panel information used by the UIM to perform a specified function. The exit program can prevent the UIM from processing the function. For example, the exit program could intercept a function key, perform some other function, and tell the UIM to not process the function key. While the UIM does not prevent this type of thing, it is the application developer's responsibility to understand enough about UIM processing to ensure that things work properly.

The action performed by the UIM is determined before the exit program is called. Some actions, such as whether or not to perform the action list processing, depend on the contents of dialog variables or list entries. Changes to these variables or list entries do not cause the UIM to evaluate the determined action again.

Dialog variable substitution into command strings is not done until after the exit program is called; changing dialog variables can affect the final, submitted command.

The exit and cancel flags for the job are not reset before the exit program is called, and they are not checked after the exit program returns control to the UIM. Therefore, exit and cancel flags should not be turned on by the exit program.


Authorities and Locks

None.


Required Parameter Group

General panel checking information
INPUT; CHAR(*)

A structure that provides information related to the user request. For details, see Single Parameter Structure.

Type of call
INPUT; BINARY(4)

This parameter must be set to the following value:


Application handle
INPUT; CHAR(8)

The application handle of the application that is currently being processed by the UIM.

Panel name
INPUT; CHAR(10)

The name of the panel that is currently being processed by the UIM.

Function key pressed
INPUT; BINARY(4)

The function key that is pressed:

The general exit program is not called for any other keys.

Function key qualifier
INPUT; BINARY(4)

Provides information about the function that will be performed unless the exit program returns through a CPF6A02 message:


Option number
INPUT; BINARY(4)

When the parameter for the function key qualifier indicates that the UIM is processing a menu item, this parameter is set to the option number of the menu item selected by the user.

When the parameter for the function key qualifier indicates that the UIM is processing a pull-down choice, this parameter is set to the option number of the pull-down choice selected by the user.

For all other values for the function key qualifier, this parameter is not set.

Pull-down field name
INPUT; CHAR(10)

The name of the pull-down field from which the pull-down choice is selected. If the pull-down field does not have a name, this parameter is set to blanks.

For all other values of the function key qualifier, this parameter is not set.

This parameter is available only when the interface level is set to two or greater.


Single Parameter Structure

For detailed descriptions of the fields in this table, see Field Descriptions.



Field Descriptions

Application handle. The application handle of the application that is currently being processed by the UIM.

Function key pressed. The function key that is pressed:

The general exit program is not called for any other keys.

Function key qualifier. Provides information about the function that will be performed unless the exit program returns through a CPF6A02 message:


Option number. When the field for the function key qualifier indicates that the UIM is processing a menu item, this field is set to the option number of the menu item selected by the user.

When the field for the function key qualifier indicates that the UIM is processing a pull-down choice, this field is set to the option number of the pull-down choice selected by the user.

For all other values for the function key qualifier, this field is not set.

Panel name. The name of the panel that is currently being processed by the UIM.

Pull-down field name. The name of the pull-down field from which the pull-down choice is selected. If the pull-down field does not have a name, this field is set to blanks.

For all other values of the function key qualifier, this field is not set.

This field is available only when the field for the structure level is set to two or greater.

Reserved. A reserved field.

Structure level. The interface level supported by this structure, indicating which fields and values are available for the current interface level.

Type of call. This field must be set to the following value:




Exit program introduced: V2R2

[ Back to top | User Interface Manager APIs | APIs by category ]