Activate objects created with @...GET commands
[COLOR SCHEME <color scheme> | COLOR <color code>]
[LOCK | NOLOCK]
The READ command activates all objects created with the @...GET command. If no @...GETS are pending, the READ command waits for any key to be pressed. Normally, the READ command will clear the GETS after screen input has completed. A READ can be terminated in several ways. Moving forward past the last object or backward past the first object, if the CYCLE clause is not specified, pressing the [EXIT/SAVE] key, or selecting an object that was designed to terminate the READ. Calling an event procedure from an active object and issuing another READ allows for the creation of nested READs. The READ commands can be nested to a depth of five levels.
If the GET fields that you have specified are fields from a table as opposed to memory variables, then the Recital/4GL will automatically lock all records in the designated tables, if the active table is opened for shared use.
If SET MOUSE is ON, cursor keys will move the cursor anywhere on the screen rather than just from field to field. If SET NAVIGATE is ON, the cursor moves to fields following the direction specified by the key being pressed, rather than following the order of the GETS on the form. When the RETURN key is pressed, the cursor moves to the nearest field when SET NAVIGATE is ON.
Note: If an attempt is made to exit from a form by pressing the [EXIT/SAVE] key, and some of the fields below the current one have the MUST_ENTER attribute, then Recital will beep, indicating an error and position the cursor on the MUST_ENTER field.
COLOR SCHEME <color scheme> | COLOR <color code>
The color of the current @...GET can be set by including the number of an existing color scheme using the COLOR SCHEME syntax or by including a color pair using the COLOR <standard/enhanced> syntax.
The CYCLE keyword prevents the READ from being terminated when you move forward past the last object, or backwards past the first object. Instead, if you are on the last object and you move forward, the first object gets focus and if you are on the first object and move backwards past the first object then the last object gets focus.
LOCK | UNLOCK
The LOCK keyword locks all records accessed from the READ. The UNLOCK keyword makes all fields accessed by the READ read-only.
The NOCLEAR keyword disables the erasing of the screen when a format file is processed.
The NOMOUSE keyword only applies to Recital Mirage applications. It forces data entry to occur in the order of the @…GETs on the screen as it would in a Recital Terminal Developer environment.
The NOREFRESH keyword prevents the initial contents of the GET fields from being displayed. It is most useful when you have a lot of CALCULATED BY fields.
The NOUPDATE option prevents updating of the index files. This should only be used if no fields are updated which affect the index key.
The SAVE keyword causes the GETS to remain active, so that subsequent reads can be executed in a loop, without having to reissue the @...GETs.
The TIMEOUT clause determines how long in seconds, <expN1>, the READ will wait for user input before exiting automatically.
The VALID clause causes <expL1> to be evaluated before the READ is exited. If <expL1> evaluates to true (.T.), the read is exited, if <expL1> evaluates to false (.F.), the read remains active.
The WHEN clause determines if the READ is activated. The expression <expL2> must evaluate to true for the READ to be activated, otherwise the READ command is ignored.
mvar = "xxx" @10,10 GET mvar read