HB_FEOF()
Check for end-of-file.
- Syntax
-
- HB_FEOF( <nHandle> ) --> lIsEof
- Arguments
-
- <nHandle> The handle of an open file.
- Returns
-
- <lIsEof> .T. if the file handle is at end-of-file, otherwise .F.
- Description
-
- This function checks an open file handle to see if it is at E-O-F.
- If the file handle is missing, not numeric, or not open, then this function returns .T. and sets the value returned by FERROR() to -1 (FS_ERROR) or a C-compiler dependent errno value (EBADF or EINVAL).
Examples
nH:=FOPEN('FILE.TXT')
? FREADSTR(nH,80)
IF HB_FEOF(nH)
? 'End-of-file reached.'
ELSE
? FREADSTR(nH,80)
ENDIF
- Status
- Ready
- Compliance
-
- This function is a Harbour extension
- Files
-
- Library is rtl
- See Also