This chapter shows a user the basics of running a Process Module that was generated by DataPaint. The form that was created in the Developer’s Tutorial is used in this section. Before starting the tutorial, there are a few basic operations that a user should understand.
You start the Process Module by giving a USE PM command at the ACCENT R asterisk prompt:
*USE PM EMPLOYEE_UPDATE
If the application developer related the Data Set as a Schema Definition or Index Definition in DataPaint, you will need to add an EQUATE clause to the USE command to specify the name of the Data Set or Data Index that you want to use:
*USE PM EMPLOYEE_UPDATE EQUATE {ds_name; di_name} TO designator
See the ACCENT R Reference Manual for details.
The form uses menus that list the options available at any given point. To select an item on a menu, use the arrow keys to move the cursor to that item. After the cursor is positioned on the item, press the Return key.
You can also type the first letters of the menu item name to move the cursor to the item. If the first letter of the item name is unique in the menu, only one character needs to be entered to move to that selection. If more than one letter is required to make the item name unique and it is not the first one in the list, you need to type additional letters.
The cursor shows the position on the screen where data can be entered or changed. The arrow keys on the keyboard are used to move the cursor up, down, or across the screen. You can use the arrow keys to move from field to field. You can also press the Return key or the Tab key to move to the next field.
The cursor automatically moves to the next field if the number of digits or characters entered from the keyboard equals the width of the data entry area.
The form has two types of context-sensitive help. The first type is for the selections on the menus. This type of help is in every Process Module generated by DataPaint. The second type is help provided by the application developer for the data fields in the MAIN Data Set. For both types, you display the help text by positioning the cursor and pressing the Question Mark (?) key. After you have read the help text, you can go back to the form by pressing the Return key.
If there is no help text defined for an item, the terminal beeps when you press the Question Mark (?) key.
In some functions, you use PF (Program Function) keys to tell DataPaint what operation to perform. Anytime you are instructed to press a PF key, be sure that you press one of the PF keys that is on the numeric keypad on the right-hand side of the keyboard.
The Control-R character can be used at any time to redisplay the current screen. This is helpful if unwanted data has appeared on the screen such as mail notification messages or random characters from communication line errors.
You enter a Control-R by holding down the Control key, pressing the R letter key, and then releasing the Control key. The Control key is often abbreviated Ctrl or Ctl and it is usually in the lower left-hand corner of the keyboard near the Shift key.
If any invalid character is entered (such as entering an alphabetic character in an integer field), the terminal beeps and the character is ignored.
Each time you press a character key, the cursor moves from left to right.
When you enter digits into an integer field, the digits shift to the left and the cursor remains at the right most column. The digits are displayed on the screen according to the specified picture format.
For a numeric field, the cursor points at the column immediately left of the decimal point. As the digits are being entered, they shift to the left and the cursor remains at the same column position. The cursor moves to the right when the decimal point is entered. The digits are displayed on the screen according to the specified picture format.
A date field can be entered in the format MM/DD/YY if the American Date option is enabled. If the European Date option is enabled, a date field can be entered in the format DD/MM/YY or DD/MM/YYYY. If the ISO Date option is enabled, a date field can be entered in the format YY/MM/DD or YYYY/MM/DD. After the date field is completely entered, the date value with the specified date format is redisplayed on the screen.
While entering a value into a data field, the only editing allowed is deleting the characters using the Delete or Rubout key.
However, for character fields you can enter edit mode and use a complete set of edit functions (see below).
When entering or changing data, you can enter edit mode to modify the data instead of retyping the entire field.
At any time during data entry for a character field, you can enter Control-V to enter the edit mode. To exit edit mode, enter another Control-V. The possible editing operations are listed on the next page.
Operation |
Command |
Move left |
Left arrow, ^D |
Move right |
Right arrow, ^F |
Move to end |
^E |
Move to beginning |
Backspace, ^H |
Delete left |
Delete/Rubout |
Delete forward |
^K |
Delete from beginning |
^U |
Delete word |
Linefeed |
Insert/Overstrike |
^A |
Enter/exit |
^V |
Each of these editing operations is explained below.
Left arrow or Control-D (^D) |
This command moves the cursor one character to the left. If the cursor is already at the beginning of the character string, the cursor will not move. |
Right arrow or Control-F (^F) |
This command moves the cursor one character to the right. If the cursor is already at the end of the character string, the cursor will not move. |
Control-E (^E) |
This command moves the cursor to the end of the character string. |
This command moves the cursor to the beginning of the character string. |
|
This command deletes one character to the left of the cursor. |
|
Control-K (^K) |
This command deletes the character pointed to by the cursor ("delete forward"). |
Control-U (^U) |
This command deletes all the characters from the beginning of the field (data entry area) to the character to the left of the cursor. |
Linefeed (LF) |
This command deletes the word to the left of the cursor. A "word" is a sequence of characters separated by any white space characters or special characters. Note that the following are not considered special characters in edit mode: % * ^ _ ~ |
Control-A (^A) |
This command switches between insert and overstrike mode. When you first enter edit mode, you are in overstrike mode. |
Control-V (^V) |
This command enters and exits edit mode. |
Once you are in edit mode, the Question Mark (?) key (for help) is disabled. The terminal beeps if the Question Mark (?) key is pressed during edit mode.
The terminal beeps if the number of characters entered exceeds the field width. In this case, the cursor does not advance to the next data field as it does in non-edit mode.
When you exit edit mode, if the data you entered does not fill the entire field width, the cursor remains in the current data field. Otherwise, the cursor advances to the next data field automatically.
The terminal beeps if you try to use the Control-V (^V) command on an integer field or a date field.
Start the Process Module:
*USE PM EMPLOYEE_UPDATE
The Employee Update form appears on the screen.
Enter the letter G. Note how the cursor moves to the first menu selection that starts with G. You could have also used the right arrow key to move the cursor to Get.
Press the Question Mark (?) key. A help message for the Get function appears on the screen.
After reading the help message, press the Return key. The screen goes back to the way it was before the help message was displayed.
With the cursor still positioned on Get, press the Return key.
Move the cursor to Last. Press the Return key. This will retrieve and display the last record in the Data Set.
Move the cursor to Match and press the Return key. The message "Enter PF4 to GET the record" appears at the top of the screen. You are asked to enter the key value of the record to retrieve.
Note: Mode in the upper right-hand corner of the screen says "Get". This helps you keep track of what you are doing.
Enter the value 34532111. Press the PF4 key. Anytime you are instructed to press a PF key, be sure that you press the PF key that is on the numeric keypad on the right-hand side of the keyboard. After you press the PF4 key the record is retrieved and displayed.
In the previous step, there was a record in the Data Set with a key value that exactly matched the key value you entered on the screen.
Next, we will enter a key value for a record that does not exist in the Data Set. Move the cursor to Match on the Get menu and press the Return key.
The message says to use Get Next or Get Prior to "fit". This means that you should do a Get Next or Get Prior to retrieve the record with a key value that is closest to the key value you entered. After reading the message, press the Return key and you will go back to the Get menu.
For another example of "fitting" key values, see the topic Get Match in the User’s Reference.
Note: Mode in the upper right corner of the screen says "Modify".
Note: You could have chosen No if you had changed your mind about deleting the record.
This completes the DataPaint User’s Tutorial. For more detailed information on functions and menus, see the User’s Reference section.