19.1.6 Reading Records from a File
The GET statement reads one logical record into the buffer.
In the following example, the first GET reads a group of four
records (a total of 80 bytes) from the file on channel #5 and
transfers the first 20 bytes to the record buffers. Successive
GET operations read 20 byte records to the record buffer
performing an I/O to the tape every 4 records.
OPEN "MT0:TEST.DAT" FOR INPUT AS FILE #5%, &
ORGANIZATION SEQUENTIAL FIXED, RECORDSIZE 20%, &
BLOCKSIZE 4%, ACCESS READ
B$ = ""
WHILE B$ <> "NO"
GET #5
MOVE FROM #5, A$ = 20
PRINT A$
LINPUT "Do you want another record"; B$
NEXT
CLOSE #5
END