EasyManua.ls Logo

Apple IIe - File Management: OPEN, CLOSE, READ, WRITE

Apple IIe
320 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
214
Apple
lie
Users
Handbook
Another
difference
between
random
and sequential files
is
the
way in
which
each
file
is
accessed.
Direct
Access
of
any
record
in
a
random
file
is
possible regardless
of
that record's
location
within
the
file.
By
direct
access,
we
mean that any record in
the
file
may be
retrieved regardless
of
its
position,
without
having
to
search
through
the
entire
file
to
find
it.
Records in a
sequential
file
can
only
be
retrieved by
sequential
access.
In
sequential
access,
the
record
search begins
with
the
first
record
in
the
file
and must
continue
until
the
desired
record
is
found.
Opening
Sequential
Files
A
diskette
file
must be
opened
before
it
can be accessed by a
program
.
When
a
file
is
opened,
DOS
will
check
to
see
if
the
specified
file
is
on
disk, and
if
so,
where
it
is
located. OPEN also
reserves a 595-byte
buffer
for
input
and
output
to
the
file.
Configuration
OPEN
filename [ ,
Sx,
Vx,
Dx]
If
the
specified
filename
is
not
present
on
the
diskette,
DOS
will
create an
entry
for
that filename in
the
diskette's
directory.
OPEN
must be specified
within
quotes in a PRINT
statement.
OPEN
must be preceded
with
Ctrl-D.
In
the
following
statements,
a
filename
TEXT
A
is
created
on
the
default
drive:
100
D$
=
CHR$(4)
200
PRINT
D$;
"OPEN TEXTA"
300
END
Writing to
Sequential
Files
Information
is
sent
to
the
diskette
via
the
PRINT
statement just
as
data
is
sent
to
the
display
or
printer.
However,
before
data can be

Other manuals for Apple IIe

Related product manuals