&OISK* '!'he &DISK* the first read/write NONE. EXEC Special Variables special variable contains the one-character mode letter of
read/write disk in the CMS search order. If you have no
disks accessed, this special variable contains the value You may assign a value to the &DISK* special variable for your own
use; if you do so, however, you will not be able to use it to obtain the
filemode letter of a read/write disk. &OISK? You can use the &DISK? special variable in an EXEC to determine which
read/write disk that you have accessed has the most space on it. If you
have no read/write disks accessed, &DISK? contains the value NONE. You may assign a value to the &DISK? special variable for your own
use; if you do so, however, you will no longer be able to locate the
read/write disk with the most space. &OOS special variable contains one of the two character values ON or OFF, depending on whether the eMS/DOS environment is active. If you
have issued the command:
set dos on
then the &DOS special variable contains the value ON. You may set or change the value of the &DOS special variable for your
own use; if you do so, however, you will not be able to test whether the CMS/DOS environment is active.
&EXEC &EXEC special variable is the filename of the EXEC file. You cannot
set this variable explicitly but you can examine and test it.
&GLOBAL &GLOBAL sDecial variable contains the recursion level of the EXEC currently executing. Since the EXEC interpreter can handle up to 19
levels of recursion, the value of &GLOBAL ranges from 1 to 19. You cannot set this variable explicitly, but you can examine and test it. Section 5. EXEC Control Statements 301
EXEC Special Variables
&GLOBALn &GLJBALn special variable represents the variables &GLOBALO through &GLOBALg. You can set these variables only to integral numeric values.
Thev are all initially set to 1. Unlike other EXEC variables, these can
be used to communicate between different recursion levels of the EXEC inter preter. &INDEX The &INDEX special variable contains the number of arguments passed to
the EXEC procedure. Since up to 30 arguments can be passed to an EXEC procedure, the value of &INDEX can range from 0 through 30. Although you cannot set this variable explicitly, it is reset by an &ARGS or &READ ARGS control statement. &INDEX can be examined to
determine the number of active arguments in the EXEC procedure.
&LINENUM
The &LINENUM special variable contains the current line number in the EXEC file. You cannot explicitly set this variable but you can examine
and test it.
&READFLAG The &READFLAG special variable contains one of two literal values: CONSOLE or STACK. If there are stacked lines in the terminal input
buffer (console stack) &READFLAG contains the value STA:K and the next
read request results in a line being read from the stack. If not, then
the next read request results in a physical read to the terminal, and
the value of &READFLAG is CONSOLE. You cannot explicitly set this
variable but you can examine and test it.
&RETCODE
The &RErCODE special variable contains the return code from the most
recently executed CMS command. &RETCODE can contain only integral
numeric values (positive or negative), and is set after each CMS command
is executed. You can examine, test, and change this variable but
changing it is not recommended.
&TYPEFLAG
The &TYPEFLAG special variable contains one of two literal values: RT
(resume typing) or fiT (halt typing). It contains the value HT when
terminal display has been suppressed by the Immediate command RT= It
contains the value RT when the terminal is displaying output. You cannot explicitly set this variable, but you can examine and test it. 302 VM/370 CMS Command and Macro Reference
Previous Page Next Page