|
ReadFileLine()
Reads a line of the contents of a binary file
previously opened using
OpenFile().
Syntax
ReadFileLine(<cFile>) --> cData
Arguments
<cFile> --> is the name of the file to
read from disk. A path and drive letter should be specified if
applicable.
Returns
Returns a line of data read from the disk file as
a string.
Description
This function is used to read the contents of a
binary disk file. The file must already have been opened using
OpenFile().
After you have completed reading the file, it must be closed using
CloseFile().
Example
cFile :=
"C:\CAPITAL\Mydata.dat"
cData := ""
If
OpenFile(cFile)
* Read 1 line of data
until end reached
* :LoopRead
cData :=
ReadFileLine(cFile)
If ( .Not.
IsFileEnd(cFile) ) Goto LoopRead
CloseFile(cFile)
____________________________
Related Topics
Business
Function List
CloseFile()
IsFileEnd()
OpenFile()
ReadFile()
WriteFile()
WriteFileLine()
|