ALTHELP (Alternative Help Key) keyword for display files

You use this file-level keyword to assign a command attention (CA) key as an alternative Help key.

When either the Help key or the CA key is pressed, the help function is called.

The format of the keyword is:
ALTHELP[(CAnn)]

The valid values for the optional parameter are CA01 through CA24. If the parameter is not specified, CA01 is the default.

The HELP keyword must also be specified, either at the file level or on at least one record in the file. ALTHELP applies only to records for which the HELP keyword also applies. If HELP is specified at the file level, it applies to all records in the file; thus, ALTHELP also applies to all records in the file. If HELP is specified at the record level, ALTHELP applies only to those records that have the HELP keyword specified.

If you specify a response indicator on the HELP keyword, the response indicator is set on and control is returned to your program when either the Help key or the CAnn key is pressed.

If you specify option indicators on the HELP keyword, the same option indicators apply to the ALTHELP keyword. That is, both the Help key and the CAnn key are active when the indicator condition is true.

The following keywords cannot be specified in a file with an ALTHELP keyword that has no parameter (CA01 default):

Similarly, the following keywords cannot be specified in a file with ALTHELP(CAnn) (where nn is the same number):

You cannot specify RETKEY or RETCMDKEY in a file with the ALTHELP keyword.

Option indicators are not valid for this keyword.

Example

The following example shows how to specify the ALTHELP keyword.

|...+....1....+....2....+....3....+....4....+....5....+....6....+....7....+....8
     A                                      ALTHELP
     A                                      HELP(01 'HELP KEY PRESSED')
     A          R RECORD
     A            FIELD1        20A     5  5
     A

The CA01 key is an alternative Help key. If the user presses the CA01 key or the Help key, response indicator 01 is set on and control returns to the application program.