Modes and Fields that Can Be Changed
The following table indicates how the screen processing mode affects whether or not fields on the screen can be changed.
Fields that use the *INOUTCOND field conditioning attribute to control when a field can or cannot be changed are not subject to the rules specified in this table.
|
Note that when a list is initialized (with the INZ_LIST command), or has an entry added (with the ADD_ENTRY command) or updated (with the UPD_ENTRY command) the mode is "set" when the command is executed, NOT when the list is displayed.
For instance the commands:
SET_MODE TO(*DISPLAY)
ADD_ENTRY TO_LIST(#BROWSE)
or just
ADD_ENTRY TO_LIST(#BROWSE) WITH_MODE(*DISPLAY)
and then
SET_MODE TO(*CHANGE)
ADD_ENTRY TO_LIST(#BROWSE)
or just
ADD_ENTRY TO_LIST(#BROWSE) WITH_MODE(*CHANGE)
would cause the first entry in the list to be "protected" and the second entry in the list to be "input capable". This is because the mode of a list entry is "set" at the time the entry is added to (or updated into) the list, not at the time that the list is displayed.
The SELECTLIST command has options that allow only entries in a list to be processed according to the "mode" that was active when the entry was added or updated last. Refer to the SELECTLIST command for more information.
Note that all list processing commands (e.g.: ADD_ENTRY or UPD_ENTRY) have an optional parameter to allow the mode of the individual list entry to be set, regardless of the current mode of the program. This is illustrated by the "or just" examples above.