Lines |
Explanation |
4-42 |
The layout segment that defines the menu display format. |
5 |
The MENU statement specifies that the menu has 15 rows and 60 columns with a normal rendition. The menu will be displayed on the screen starting at row 5 and column 5. |
6 |
The SELECTION statement indicates that the item description should always be displayed and the area to highlight is the length of the keyword. The rendition used to highlight the keyword is reverse video. |
7 |
The BORDER statement specifies a border with a title for the menu. The title for the menu is in reverse video. |
9 |
The LINE statement specifies a horizontal line at row 13 of the menu. |
10-11 |
The MESSAGE statements cause two lines of text to be placed at row 14, column 20 and row 15, column 23 of the menu. |
13-14 |
These statements describe the first item. This first item has the keyword ADD at row 3 and column 5 with normal rendition. The item description, "Add a new customer row", starts at row 3 and column 15 of the menu with normal rendition. |
15-17 |
The help box for this item has 4 rows and 60 columns. The help box is displayed at row 18 and column 5 of the screen. The display position of the help box is relative to the screen not the menu. The help message in the help box is specified by the TEXT statements. |
19-23 |
These statements describe the second item. |
25-29 |
These statements describe the third item. |
31-35 |
These statements describe the fourth item. |
37-41 |
These statements describe the fifth item. |
45 |
The GENERATE statement checks the syntax of the menu description in the layout segment. If an error is detected, the corresponding error message is displayed and menu_id has the value of zero. |
46 |
The MENU statement displays the menu shown in Figure 6 and activates the menu operation if a menu ID other than zero is returned by the GENERATE statement. |
47-90 |
After the selection is made the proper action is taken. The system field @MENU_CHOICE is used to decide which menu selection was made, but @MENU_KEYWORD also contains the associated keyword. @MENU_KEYWORD should be used instead of @MENU_CHOICE when possible. This will allow the menu to change without changing the affected PM’s and CM's. If the Return key is pressed at the keyword DELETE, the system field @MENU_CHOICE will have the value of 3. This is because the DELETE item is the number 3 item in the layout segment. The system field @MENU_KEYWORD will have the text DELETE. |
100 |
This FLUSH statement removes the menu from memory. |