In the previous posts you have seen about CICS and its basic programming. In this article, we will be seeing about creating and assembling of CICS Maps. Basic Macro Support (BMS) is the programming language used to develop MAPSET, MAPS and FIELDS.
Any program must be coded in PDS. Similarly, for Assembler/BMS program, a separate PDS member is coded. In order to develop the screen, mapset is used. A Mapset is a collection of Maps and a Map is defined as a collection of Fields. Individual blocks in a screen is called Maps.
Every CICS Map consist of elementary fields, which is a data item. There are mainly two types of fields. Data-entry field and Display-only field. Data-entry fields are meant for Input where some user can type some data. Display-only fields are used to display titles, labels, captions or alert messages.
Every field on CICS screen consist of characteristics called Attributes that control the look and feel of the field. It is an extra byte that shows the end of a field i.e. a field does not end until next attribute byte comes on. Each field is preceded by an attribute byte. For data entry fields a closing attribute byte has to be explicitly coded after the data entry field. This is because if it is not done, the data-entry field might extend to the next line.
Some of the important parameters to code attribute byte is intensity, protection and shift.
Intensity – Related to the appearance of the field. There are mainly three types. NORM for Normal Intensity, BRT for Bright Intensity (eg: error messages) and DRK for Dark Intensity (to hide characters by darkening them like passwords)
Protection – It is used to specify whether a user is allowed or not to enter data into a field. PROT is used to specify that the field is protected and it is a display only field. UNPROT specifies that the field is unprotected and is a data entry field. ASKIP is a special type of skip-field that is protected where the cursor is automatically skipped to next unprotected field.
Shift – It is used to determine whether the keyboard is alphanumeric or numeric shift. NUM is used to enter numeric digits (0-9) and ANUM is used for alphanumeric.
The Attribute byte is 8-bit data. The first seven bits consist of the intensity, protection and shift values. The last bit is used to contain the Modified Data Tag (MDT). If MDT is 1, it indicates that the data in the field has been changed and if MDT is 0, it means that data is not changed.