AT&T 6300 Programmer's Manual page 377

Gwbasic by microsoft
Hide thumbs Also See for 6300:
Table of Contents

Advertisement

Syntax I
Syntax 2
device
filename
model
OPEN
Statement
Allows I/O to a file or device. OPEN is usually
used in a program.
OPEN {devicelfilename} [FOR model] AS
[#]filenum [LEN
=
reel]
OPEN mode2, [#]filenum, {devicelfilename}
[ ,reel]
is a string expression which specifies the device to be opened
is a string expression which specifies the file to be opened. It
may optionally include a device.
is a literal string not enclosed in quotation marks. It
determines the initial file pointer position and the action to
be taken if the file does not exist. The valid modes and
actions taken are:
INPUT
OUTPUT
APPEND
Specifies sequential input mode. Positions
the pointer to the beginning of an existing
file. A "File not found" error is given if the file
does not exist.
Specifies sequential output mode. Positions
the pointer to the beginning of the file. If the
file does not exist, one is created.
Specifies sequential output after the last record
on the file. Positions the pointer to the end of
the file. If the file does not exist, one is created.
If
the FOR 'model' clause is omitted, the
initial position is at the beginning of the file.
If
the file is not found, one is created. This is
the Random I/O mode. That is, records may
be read or written at any position within the
file.
7-221

Advertisement

Table of Contents
loading

Table of Contents