AT&T 6300 Programmer's Manual page 116

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

Advertisement

Disk File Handling
ACCESSING A RANDOM ACCESS FILE
Reading a random access file requires the
following steps.
1 OPEN the file in "R" mode.
OPEN uR"11#111uFILE",132
2 Use the FIELD statement to allocate space
in the random buffer for the variables that
will be read from the file.
FIELD #1 , 1 20 AS NS,I 4 AS AS,IS AS PS
3 Use the GET statement to move the desired
record into the random buffer.
GET #1 , 1 CODE%
4 The data in the buffer may now be accessed by
the program. Numeric values must be converted
back to numbers using the "convert" functions.
CVI converts numeric values to integer values,
CVS converts numeric values to single precision
values, and CVD converts numeric values to
double precision values.
4-32

Advertisement

Table of Contents
loading

Table of Contents