MLTCHCFLD (Multiple-Choice Selection Field) Keyword for Display Files--Example

Figure 201 shows how to specify the MLTCHCFLD keyword:

Figure 201. Specifying the MLTCHCFLD Keyword

|...+....1....+....2....+....3....+....4....+....5....+....6....+....7....+....8
A
A          R RECORD
A            F1             2Y 0B  3 35MLTCHCFLD
A  01                                  CHOICE(1 '>Undo       ')
A                                      CHOICE(2 &MARKTXT);
A                                      CHOICE(3 '>Copy       ')
A                                      CHCCTL(1 &CTLONE1 MSG1111 QUSER/A)
A                                      CHCCTL(2 &CTLTWO1 &MSG1 &LIB/&MSGF);
A                                      CHCCTL(3 &CTLTHR1);
A            CTLONE1        1Y 0H
A            CTLTWO1        1Y 0H
A            CTLTHR1        1Y 0H
A            MSGF          10A  P
A            LIB           10A  P
A            MARKTXT       10A  P
A

The CHCCTL keyword is required for each CHOICE keyword used for the MLTCHCFLD.

On input, the hidden field for the CHCCTL keyword indicates whether or not the choice was selected. 0 indicates the choice was not selected; 1 indicates the choice was selected. On output, the hidden field controls the availability of the choice, and is used to set a default selection of a choice. 0 indicates the choice should be available, 1 indicates the choice should be selected by default, and 2 indicates the choice is unavailable. Other values such as 0 are truncated.