Most of the time, you need use only the one list of user function keys. However, if you are converting from another dialect of COBOL, you might have some programs that expect the values returned from the default user key list and some programs that expect the values returned by the function keys in some other dialect of COBOL. To enable you to do this, the compatibility key list is provided. This works in exactly the same way as the normal key list. Any program can use either the default user key list or the compatibility list, but not both.
If you want all programs in your system to use the compatibility key list, you can use Adiscf to select its use. If you want different programs to use different lists, insert the following call into your programs to select the list you require:
call x"AF" using set-bit-pairs key-list-selection
where set-bit-pairs and key-list-selection are defined in the Working-Storage Section of your program as follows:
01 set-bit-pairs pic 9(2) comp-x value 1. 01 key-list-selection. 03 key-list-number pic 9(2) comp-x. 03 filler pic x value "1". 03 filler pic 9(2) comp-x value 87. 03 filler pic 9(2) comp-x value 1.
where key-list-number is set to one of the following values: