Get

Reads data from an open disk file into a variable.

Syntax

file.Get Data , [Recnumber]

The parts of the Get statement syntax are described in the following table.

Part Description
Data Required. Variant variable into which data is read.
Recnumber Optional. Variant (Long). Record number (Random mode files) or byte number (Binary mode files) at which reading begins.

Remarks

Data read with Get is usually written to a file with Put.

The first record or byte in a file is at position 1, the second record or byte is at position 2, and so on. If you omit Recnumber, the next record or byte following the last Get or Put statement (or pointed to by the last Seek function) is read.

For files opened in Random mode, the following rules apply: