Read a line from a text file.
The operator fread_line reads a line from the current input file (including the line skip). If the end of the file is reached IsEOF returns the value 1, otherwise 0.
The maximum string length is 1024 character (including the end of string character).
|
FileHandle (input_control) |
file -> integer |
| File handle. | |
|
OutLine (output_control) |
string -> string |
| Read line. | |
|
IsEOF (output_control) |
integer -> integer |
| Reached end of file. | |
do {
fread_line(FileHandle,&Line,&IsEOF) ;
} while(IsEOF==0) ;
If the file is open and a suitable line is read fread_line returns the value 2 (H_MSG_TRUE). Otherwise an exception handling is raised.
fread_line is reentrant and processed without parallelization.
open_file, close_file, fread_char, fread_string
Foundation