FileAtEOF()
Summary
Test to see if the end of file has been reached.
Syntax
result = FileAtEOF(file f)
| Argument | Contents |
|---|---|
| f | The handle of the file |
Returns
An integer, 1 if the end of file has been reached or 0 if it has not been reached.
Example
fptr = OpenFile("data.txt", "r")
While !FileAtEOF(fptr) do
ShowMessage(ReadLine(fptr))
end
Error Codes
| Error Type | Meaning |
|---|---|
| Error | File is not open |
See Also
| Function | Summary |
|---|---|
| OpenFile() | Opens a text or binary file on disk |
| FileGetPosition() | Gets the current Read/Write position of a file |
| FileSetPosition() | Sets the current Read/Write position of a file |