Greetings,
I have learned that disk file operations on Jabaco are different than VB6. So I have studied some examples on the Community. I have tried a number of different code examples. The one below is intended to be a sequential write, then read, but doesn't work as intended. What is wrong with this code?
Public Sub cmdTest_Click()
Dim myFile As VBFileHandler
' write
myFile = Open("C:\About\Test\Test.txt",Output)
Call Write(myFile, "1")
Call Write(myFile, "2")
Call Write(myFile, "3")
Call Close ()
'read
myFile = Open("C:\About\Test\Test.txt", Input)
MsgBox readline(myFile) ' displays "3" ?
MsgBox readline(myFile) ' displays nothing ?
MsgBox readline(myFile) ' displays nothing ?
Call Close()
End Sub
One final question: Is it possible that a single Write or Read can process more than one data variable, for example? write ... "1", "2", "3"