|
|
|
|
Parameters of the procedure used by fReadLine WLanguage procedure ("Callback") called by fReadLine for each line read in the file. This procedure can be a local, global or internal procedure.
FileNameAndPath is string
FileID is int
NumberLinesRead is int = 0
INTERNAL PROCÉDURE AnsiCallback(LineRead is ANSI string)
Trace("Callback | Line read: " + LineRead)
END
FileNameAndPath = "C:\Directory\AnsiFile.txt"
FileID = fOpen(FileNameAndPath, foAnsi)
IF FileID = -1 THEN
Error(ErrorInfo(errMessage))
ELSE
NumberLinesRead = fReadLine(FileID, AnsiCallback)
IF ErrorOccurred THEN
Error(ErrorInfo())
END
Trace("Number of lines read: " + NumberLinesRead)
fClose(FileID)
Trace("Read operation completed")
END
Syntax
<Result> = fReadLine_Callback(<Row read>)
<Result>: Boolean - True if the line was read,
- False otherwise.
<Row read>: Character string Content of the line read in the file.
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|