Equinox Online Help - Language Reference - A to Z
FileReadLine |
|
---|---|
Applies to | |
Syntax | FileReadLine HandleItem, LineItem |
Action | [Statement] Reads one line from a sequential file into a string |
Scope | Usable anywhere |
Notes | Data is read from the file into the LineItem specified as an argument. The item is read up to the end of line delimiter specified in the FileDelimiters statement. If the FileDelimiters statement has not been used within the Method the first end of line delimiter defaults to ASCII 13 and the second to ASCII 10 (ie CR followed immediately by LF). This statement will not work if the file has been opened as a random file. The HandleItem parameter must be of Equinox variable type Handle and is the handle of the file which was opened with the FileOpen statement. After the statement has executed, SysReply contains the number of items read The system workarea SysError is set to 4 if the end of file is detected and no items were read, 1 if an error occurs, otherwise zero. |
Category | File IO |
See Also | FileClose, FileCloseAll, FileDelimiters, FileInput, FileInputLine, FileLock, FileMovePosition, FileOpen, FilePosition, FilePrint, FileRead, FileReadLine, FileReadBinary, FileReadFile, FileUnlock, FileWrite, FileWriteBinary, FileWriteFile |
Example | This example reads two records from a sequential file which contains itemised call data from an office telephone system. The first line which contains an arbitrary transaction number is discarded. handle hnd |