Syntax:
Then:
SCREEN s
Then: SCREEN s,f
Then: SCREEN s,f,o
SCREEN has several formats available, each allowing the desired level of cursor control.
SCREEN |
Refreshes the current screen, and places cusor in first field of cursor path. |
SCREEN s |
Switches to screen "s", then positions the cursor in the first field of the cursor path |
SCREEN s,f |
Switches to screen "s", then positions the cursor at field "f". |
SCREEN s,f,o |
Switches to screen "s", then positions the cursor in field "f" at offset "o". o" is the offset within the specified field on which to position the cursor. NOTE: An offset of -1 will place the cursor in the first empty position of the field. |
Version Ref: 6.0.02
SCREEN command can switch fields in a POPUP UPDATE -, provided no screen name is passed to the SCREEN command.
Examples:
SCREEN ,33
SCREEN ,pa,"-1"
- - - - - -
When a screen number, letter, name or expression is given, SCREEN rewrites the entire screen. In other words, all SHOW or other messages are cleared from the screen, and all fields are displayed with their current value. When no screen number, letter, name or expression is given, the program rewrites and redisplays the changed fields without clearing messages or rewriting unchanged fields.
NOTE: If no cursor path is defined for a screen, and no field specified by the SCREEN command, the cursor will be put in the first non-protected field on the screen.
Version Ref: 4.5
VERY IMPORTANT: The parameters "s", "f", and "o" are expressions. Since SCREEN will recognize single number and single letter screen names, and also recognize unquoted field numbers and letters as field designations, you must enclose any of these parameters in parentheses if you want them to be resolved as expressions. The full version of the SCREEN command can therefore be thought of as follows:
Then: screen (exps),(expf),(expo)
where:
"exps"
is any expression evaluating to a screen number, letter, or name
"expf" is any expression evaluating to a field number or letter.
"expo" is any expression evaluating to an offset.
Then:
screen 3,2,"3"
Then: screen (aa),"4","3"
Then: screen A,B,"3"
Then: screen "3","2","3"
Then: screen "3","2",(aa)
Then: screen "inv","2","1"
The above are all valid commands, and:
Then:
screen 33,2,"3"
Then: screen aa,"4","3"
Then: screen A,B,3
Then: screen "3",22,"3"
Then: screen "3","2",aa
Then: screen inv,"2","1"
the above are all invalid commands and will generate an syntax error. Note that the offset parameter requires quotes if it is to be a number, it does not behave like the "s" and "f" parameters.
NOTE: If you want the cursor to go to the first available space in the field (the character after the last non-blank character), use -1 as the offset, using screen 0, field 1.
Then: screen 0,1,"-1"
or
Then: screen "0","1","-1"
NOTE: Screen formats in filePro can have names of up to 7 characters for UNIX/XENIX systems, and up to 3 characters for DOS systems. A named screen is accessible only through processing. Note that single letter screen names, if not in quotes, are always treated as uppercase. For screen names of more than one character, in quotes, case is significant on UNIX/XENIX systems, but not on DOS systems.
Description:
On the Automatic table, SCREEN is used to access one screen rather than another, and make this screen the default screen. The default screen is the screen Input processing and @KEY processing will return to when an END statement is encountered.
When a SCREEN command is encountered during Input or @KEY processing, the user is put into update mode on the designated screen. When the user presses <ESC> to record the input on this screen, processing will resume with the command immediately following the SCREEN command.
When a SCREEN command is encountered during @WLF or @WEF processing, the user is put into update mode on the designated screen. When the user presses <ESC> to record the input on this screen, processing ends. @WLF and @WEF processing are not considered Input processing. These routines run independently from Input processing, and do not affect the position of the Input processing's execution pointer. Each @WLF and @WEF routine has its own pointer, and processing ends for these special routines only when one of the specific @WLF, @WEF "closing" commands is encountered. SCREEN is one of these commands.
Restrictions:
If there is more than one SCREEN statement on an automatic processing table, only the last SCREEN statement encountered is performed.
SCREEN can only be used on Input and Automatic processing tables.