GDDM V3R2 Base Application Programming Reference
Previous topic | Next topic | Contents | Index | Contact z/OS | Library | PDF | BOOK


Selector adjunct

GDDM V3R2 Base Application Programming Reference
SC33-0868-02



The selector adjunct provides additional control over an individual field in the application data structure, and shows, after an MSGET, whether the data field has just been modified by the operator.

The control function is most useful when using MSPUT with option 1 (REWRITE) or 2 (REJECT), particularly if the application program does not maintain a complete copy of the application data area. A partially completed application structure can be used. Fields whose selector is blank are ignored and so need not be set by the application. Their value is unchanged. Fields whose selector is C'1' or C'3' are processed by placing the current data value in GDDM's copy of the data area with the value from the program's data area.

Note: Fields that do not have a selector are always processed.

The control function can also be used to set a field to its map-defined default value. This is the constant text placed into the field during GDDM-IMD's Field Definition or Field Initialization steps. This is the value of the field immediately after a mapped field is defined by MSDFLD. Note that if the field has no selector, any MSPUT call replaces this default value with the value from the application data area (even if the field is all blanks). If the field has a selector adjunct, its value can be reset to the map-defined default value by specifying a selector of C'2' on any MSPUT call.

   Notes:

1. The map-defined default character attributes are always "default." GDDM-IMD does not support character attributes.

2. An MSPUT with option 0 (WRITE) sets all fields (attributes and so on) back to their default value before processing the application data area.

When a selector value of C'2' is specified, GDDM converts it into C'3', and places the default field value into the data field in GDDM's copy of the data area so that the program can access it using MSGET. (The program's data area is not modified during an MSPUT.)

After an MSGET, a selector adjunct shows whether the field has just been modified by the operator. A value of C'1' shows that the field has been modified by one of these events:

  • The operator has typed into the field
    
    
  • The operator has selected the field with a light-pen (if the field is selectable)
    
    
  • The field has been set by AID translation.
    
    

Note: "Modified" includes the degenerate case of the operator modifying the field back to its original value.

Usually, modification indicators are reset when the operator is next given an opportunity to enter data (for example, an ASREAD). Your program can avoid this resetting by issuing an MSPUT call with option 2 (REJECT) on any map within the page, before the ASREAD call.

Go to the previous page Go to the next page



Copyright IBM Corporation 1990, 2012