hi.
how can i open file in api(this i know..) AND
start writing text from the END of the file...
Printable View
hi.
how can i open file in api(this i know..) AND
start writing text from the END of the file...
Code:'Read
Open "C:\TxtFile.txt" For Input As #1
Text1.Text = Input$(LOF(1), 1)
Close #1
'Save
Open "C:\TxtFile.txt" For Output As #1
Print #1, "Your text here"
Close #1
If you want to save the files and keep everything rather than overwriting it.
Which I believe is what you want to do:
Open "C:\TxtFile.txt" For Append As #1
Print #1, "Your text here"
Close #1
That's not an API method though. If you want to stick to pure API, use WriteFile.