FutureBasic Logo

<<    Index    >> FutureBasic

record   statement



Syntax
record [#]fileID, recordNum [, positionInRecord ]

Description
This statement sets the "file mark" position, in the open file specified by fileID. The position of the file mark determines the location in the file where the next input or output operation will occur.
If you omit the positionInRecord parameter, record places the file mark at the beginning of the record indicated by recordNum (the first record in the file is considered Record #0). If you specify positionInRecord, the file mark is placed at an offset of positionInRecord bytes past the beginning of the indicated record.
record uses the record length that was specified in the open statement when the file was opened. If no record length was specified, a default length of 256 bytes is used. If you specified a record length of "1" when you opened the file, you can set the file mark to a particular byte offset from the beginning of the file using a statement like this:

record [#] fileID, byteOffset

Note
The file mark position is also moved automatically after every input or output operation on the file.

See also
rec; loc; open; lof