Pathmaker Programming Guide
Modifying Requester/Server Pairs
Advanced Pathmaker Programming Topics
9–58 067868 Tandem Computers Incorporated
You use @CURSOR-FIELD when you want to send the SCREEN COBOL screen field
name of the current cursor position to the service.
You use @CURSOR-POSITION when you want to send the Working-Storage name of
the current cursor position to the service.
You could use @CURSOR-FIELD (or @CURSOR-POSITION) with a point field to
detect the cursor position by a list of protected fields. Because the fields are protected,
you cannot place the cursor directly in the field. Creating a point field next to each
protected field allows you to identify the cursor position.
@CURSOR-POSITION. The @CURSOR-POSITION pseudofield contains the reference
field name of the screen field in which the cursor was placed at the time of the send.
The reference field name is the elementary field name or column name of a reference
object. The syntax for qualifying reference field names in the Pathmaker user interface
is:
group-name.elementary-name
For example, suppose you have the following DDL definition:
DEF employee-name.
02 first-name PIC X(20).
02 middle-ini PIC X(1).
02 last-name PIC X(20).
END.
The reference field name of the first elementary data item in the list as you would
enter it on a Pathmaker screen is:
EMPLOYEE-NAME.FIRST-NAME
COBOL allows you to qualify a data item with either OF or IN, so the same data item
in your Custom Source File would appear as:
FIRST-NAME OF EMPLOYEE-NAME
or
FIRST-NAME IN EMPLOYEE-NAME
In contrast, the screen field name is the name that appears in the SCREEN section of
the SCREEN COBOL program that is associated with this reference field name. The
Pathmaker product generates the screen field name unless you specify a name on the
Display Detail screen.
You use @CURSOR-POSITION when:
You are not using multiple occurrences of a data item on the screen.
Data items do not require multiple levels of qualification.
The decision logic for the action should be placed in the service rather than in the
requester.