Radio Shack TRS-80 PC-3 Owner's Manual page 145

Table of Contents

Advertisement

With the third form, variables are read from the tape, starting at the current location, and loaded into the variables in the order in
which they appear in the variable list. If there are not enough values on the tape for the number of variables in the list, then zero
or NUL values are assigned to the remainder.
With the fourth form, the tape is searched for the indicated filename and the variables are loaded from the values saved in that file.
There is a special variable form which may be used in the variable list. It looks like an array variable except that an asterisk is
enclosed in the parentheses, e.g., B(*l or F$(*). This form causes all values of the indicated variable to be restored from the tape,
including the simple variable of the same name; i.e., B( *
I
restores Band B(0), B(1), B(2), etc., for as many values as were original-
ly stored. You may not read a single element of an array.
Examples
10 INPUT
#
A,B,C,
20 INPUT
#
"FIL2"; 0, E, F
30 INPUT
#
"FIL3"; G(*l
Reads three values from the current position of the tape.
Searches the tape for the file' F IL2' and reads in three values.
Searches the tape for the file 'FIL3' and reads in G and as many values of G( ) as are
available.
NOTES:
1. When the prerecorded data on tape is transferred to a variable, the data and variable should be coincident in shape (numerical
or string variable), size, and length. An error (ERROR 8) will result unless they are coincident in size and length. No error
will occur when they are not coincident in shape. In this case, however, the transfer of incorrect data may result when the
numerical data is transferred to a string variable or the string data to a numerical variable. Therefore, the data and variable should
also be coincident in shape.
2. The data transfer to variables in the fixed variables and/or in the shape of A (
) terminates when the prerecorded data on tape
is out, or when the Computer memory is filled to capacity.
145

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents