Use the BMS screen painter in CICS Option to create and modify BMS maps. You see the maps as they would appear when displayed during a CICS transaction. You can alter the appearance and function of each field in the map.
You need to have read the chapter Start Here for the Tutorials and worked through the first session, Using Mainframe Express, and the session CICS Applications, before you do this session.
You need to have installed CICS Option to do this session. We assume you are familiar with CICS on a mainframe.
This session shows you how to use the BMS painter to create and edit BMS maps and mapsets and use them in CICS applications.
This session uses the same demo application as the chapter CICS Applications.
This demo uses the project cicsdemo.mvp that you created and built in the chapter CICS Applications.
The full path is \mfuser\projects\gsdemo\cicsdemo\cicsdemo.mvp. If you use Open on the File menu, you need the Files of Type field on the Open dialog box set to Project files (*.MVP) to see this file.
In this session you:
To view the BMS maps in this project:
A BMS Painter window opens displaying the first map of acctset.bms, as shown in Figure 21-1.
Figure 21-1: The IDE with a BMS Painter Window
The BMS Painter window appears, displaying the first map of acctset.bms.
You see a full list of the maps in this mapset.
This displays the map ACCTDTL in the right-hand pane.
This displays ACCTMNU again.
To display the properties of the mapset:
This displays the Mapset Properties dialog box. (You can also display the Mapset Properties dialog box by right-clicking the mapset name in the left-hand pane and clicking Properties on the pop-up menu.)
This dialog box is where you can change the properties of the mapset.
To display the properties of a map:
This displays the Map Properties dialog box.
This dialog box is where you can change the properties of the map.
To display the properties of a field:
This displays the Field Properties dialog box. Also, the tree view in the left-hand pane expands to list the fields on this map with the selected field name, SNAMEM, highlighted. Any fields that do not have a name are shown in the tree view as "static text".
This dialog box is where you can change the properties of the field.
An alternative way of viewing field properties is as follows.
This displays the Field Properties dialog box.
When you select a field in the left-hand pane, if the right-hand pane is not already displaying the map containing that field, the right-hand pane changes to display that map.
Although color and highlight are shown on the Field Properties dialog box, and you can edit them there, there's also a short-cut you can use:
We've now finished using the BMS Painter for the moment.
As well as using the BMS painter to edit BMS maps, you can view and edit the BMS source directly.
An edit window appears showing the BMS map as text. This has loaded the same editor as you would get for a plain text file or a COBOL source file, and you have all the same editing functions available.
To create a new BMS map:
The Mapset Properties dialog box appears
The Map Properties dialog box appears
The painter is displayed with an empty map in the right-hand pane and the new mapset name and map name in the left-hand pane.
To create a field in the map
This creates some static text.
This marks the extent of the field, and initializes it to x"00" (hexadecimal 00), the initial value used for an input field. This doesn't mark it as an input field though.
Notice that the new field appears in the left-hand pane. It is shown as "static text".
This sets the "Unprotected" property, meaning users will be able to type data into this field. So it is now an input field.
Notice that the field's entry in the left-hand pane now shows its name, DEMO1.
While you're dragging it, the field is colored green. It stays green while the field is in a valid position in the map. If part of a field is in an invalid position (such as on top of an existing field) it turns red. Releasing the mouse button while part of the field is red returns the field to its original position. When the field is dragged back to its original position it turns white.
To create a new field by copying an existing one:
A new field appears at the chosen position. It has the same properties as the field you copied, and a unique name is generated for it. The new field appears in the left-hand pane as DEMO2.
If the position on the map is invalid the Paste will not complete and nothing happens.
You can drag the new field to a new position if you want to.
As well as moving individual fields you can move a block of adjacent fields:
Both fields move together to new positions.
You can also copy a block of adjacent fields:
You can also move and copy blocks of non-adjacent fields. Instead of dragging the frame to select the block of fields, select the fields as follows:
This selects it, and deselects all others.
As with all the editors in Mainframe Express, the functions such as Cut, Copy, and Paste that appear on the popup menus are also on the Edit pulldown menu.
Compiling a mapset generates a .mod and a .cpy file for use in the build of the project. There are several ways on the menus of the IDE to start a compilation. Usually the most convenient way is to click Build on the Build menu, to rebuild the project. Here will we illustrate one of the other methods.
Compiling a file invokes automatically the correct compiler for that type of file.
The .mod file is generated into the loadlib folder and the .cpy file into the copylib folder for the project (see the chapter Using Workgrouping).
The Cicsdemo project is used in a related session, Running with Multitasking. If you're planning to go onto that session, you can keep the project open.
If you want to take a break before going on to the next session, you can close Mainframe Express.
Return to the Tutorials Map in the chapter Start Here for the Tutorials and choose which session to go on to next, depending on your interests.
Comments on the books? Click Send Us Comments.
Copyright © 2001 Micro Focus International Limited. All rights reserved.
This document and the proprietary marks and names used herein are protected by international law.