English
Language : 

NSB8 Datasheet, PDF (58/158 Pages) List of Unclassifed Manufacturers – BASIC interpreter for Z80 family
OPEN
grifo®
ITALIAN TECHNOLOGY
STATEMENT:
OPEN #<file number expression>, <file name>
OPEN #<file number expression>, <file name>, <size variable>
OPEN #<file number expression> %<type expression>, <file name>
OPEN #<file number expression> %<type expression>, <file name>, <size variable>
ACTION:
The diskette file with the given name is assigned the specified file number. Until the file is closed,
it may be referenced by using the file number. The file number expression must evaluate to an integer
from 0 to 7. If the optional type expression is omitted, the named file must be of BASIC data type
for the OPEN to be successful. The OPEN will succeed if and only if the file is of the given type. The
type expression must evaluate to an integer from 0 to 127. The file name may be any string expression
and must evaluate to a legal file name as specified in section FILES. If the optional size variable is
used, the size of the successfully opened file, given in 256 byte disk blocks, will be assigned to the
specified numeric variable.
EXAMPLES:
OPEN #1,”DATA”
OPEN #17%4,”CUSTLIST”+D$
OPEN #F%T,F$,S
REMARKS:
An active file number must be freed by a CLOSE statement before it may be re used in a BASIC
program (used again in an OPEN statement).
A RUN, END, SCR, LOAD or CHAIN will close all open files.
ERROR MESSAGES:
TYPE ERROR
The named file is not of the type specified in the OPEN statement (data type, if no type is explicitly
specified).
FILE ERROR
This is caused by three conditions:
1) The file number is already assigned to a file.
2) The file name has been formed incorrectly.
3) The named file does not exist on the diskette in the specified drive.
OUT OF BOUNDS ERROR
The file number or type value is out of range.
SEE ALSO:
Section DATA FILES
Statement CLOSE
Page 46
NSB8
Rel. 5.10