qp.hlp (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
SeekEof Function
  Summary Details Example                                   Back
 
  Argument
 
    file_variable    Optional; an open text file (default is the
                     standard file Input)
 
  Returns
 
    Boolean          True if file is empty or current position is past
                     the last element in the file (ignoring blanks,
                     tabs, and end-of-line); otherwise False
 
  Description
 
    The SeekEof function indicates whether the current file position is
    beyond the last character in an open text file. It checks forward
    from the current position to the next element in the file and
    ignores any blanks, tabs, or end-of-line markers (or any character
    with an ASCII value less than 33).
 
    If SeekEof finds an end-of-file marker, the actual end of the file,
    or an empty file, it returns True. If SeekEof finds any character
    other than the ones it ignores, it returns False.
 
    SeekEof does not change the current file position.
 
    The end-of-file marker is the character CTRL+Z (ASCII 26). The
    end-of-line marker is a carriage return (ASCII 13).
 
    SeekEof differs from the Eof function by ignoring blanks, tabs, and
    end-of-line markers in determining whether the end of a file has
    been reached. Thus, SeekEof may be more useful than Eof for reading
    text files of numeric data.
 
    If file_variable is not associated with a file or if the file is
    not open when SeekEof is called, an I/O error occurs.
 
    To prevent a program from halting with a run-time error when an I/O
    error occurs, turn off I/O checking with {$I-} and check the return
    value of the IOResult function.