1
1
Fork 0
mirror of https://github.com/DualBrain/QB64.git synced 2023-11-19 13:10:13 +00:00
QB64-website/wiki/EOF.md
2022-12-24 19:12:43 -06:00

701 B

The EOF function indicates that the end of a file has been reached.

Syntax

endReached%% = EOF([#]fileNumber&)

Description

  • fileNumber& is the number of the file being read. # is not required.
  • Returns 0 until the end of a file. This avoids a file read error.
  • Returns -1 (true) at the end of the file.
  • Note that GET can return invalid data at the end of a file. Read EOF after a GET operation to see if the end of the file has been reached and discard last read.

See Also