| |
|
| Formats |
1.
Define List: IOLIST {parm[:[format]...} |
|
|
| *Note* |
The
inner set of brackets enclosing [,format]
are part of the syntax. |
|
|
| |
Where:
| parm |
Set of parameters to be used in an
input/output directive. This includes variables,
literals, Mnemonics, IOL=
options, and/or location functions such as
'@(...)'.
|
| format |
Defines how the field is formatted.
Options include:
| CHR(
len [, SEP=dlm
]) |
Variable length string
(Optional SEP= clause
indicates not to extend beyond dlm
character). When written trailing spaces
will be added or data will be truncated.
On reading trailing spaces will be
deleted. |
| CHR( dlm
[, SIZ= len ]) |
Variable length string
(Optional SIZ= clause
indicates when writting append spaces or
truncate to len characters).
When written the character identified by dlm
will be appended. |
| DEC( [ SEP,SIZ= ]
len[,scl]) |
Fixed length, explicit
decimal, sign maintained. Numeric fields
are padded with leading spaces.
Optional SEP,SIZ= clause
allows for padded numeric fields followed
by a field separator. |
| LEN(
len [, SEP=dlm
]) |
Variable length string
(Optional SEP= clause
indicates not to extend beyond dlm
character). When written trailing spaces
will be added or data will be truncated. |
| LEN( dlm
[, SIZ= len ]) |
Variable length string
(Optional SIZ= clause
indicates when writting append spaces or
truncate to len characters).
When written the character identified by dlm
will be appended. |
| STR( dlm
) |
Quoted String. |
| STR( +
) |
Special PxPlus format used
with Windx data packets. Used for INPUT
only. If parm is a numeric
variable, it receives the length of
string but does not advance. If parm
is a string variable it receives the
string value.
This option is a +PxPlus
Exclusive |
| NUM( len
[ ,scl ]
) |
Fixed length unsigned
numeric. |
| SGN( len
[ ,scl ]
) |
Fixed length signed numeric.
Sign character is trailing. |
| BIN( len
[ ,scl ]
) |
Binary numeric. |
| INT( len
[ ,scl ]
) |
Unsigned integer numeric. |
| BCD( len
[ ,scl ]
) |
Packed decimal numeric. |
| |
|
| In the above... |
|
| len |
is the length of the field
in the record. |
| dlm |
is the string whose first
character delimits the field. |
| scl |
is the optional scaling
factor to apply to the number (e.g., 2
indicates that 1.34 is output as 134). |
| |
|
|
|
| |
|
| |
|
| Description |
Use
IOLIST to define a common I/O parameter
list (IOLIST). ProvideX ignores the IOLIST
directive when it encounters it during program execution
until it is used in conjunction with file I/O directives
(e.g., READ, WRITE,
etc.) and composite string definitions. For more
information, see File Handling in the ProvideX
User's Guide. |
|
|
| *Note* |
IOLIST
must be the only directive in a statement. |
|
|
| |
|
| Examples |
0010
OPEN (20)"CSTFLE"
0020 READ (20,KEY=C$)IOL=1000
0030 LET J=J+10
0040 WRITE
(20,KEY=C$)IOL=1000
0050 WRITE (21)IOL=1010
...
1000 IOLIST
C$,C1$,C2$,C3$,J,K,L,M
1010 IOLIST
C$:[CHR(10)],C1$:[CHR(40)] |