I'm attempting to write to a text file but keep getting the same error "ERROR #62: Input past end of file" It's been so long since I've done this I know it has something to do with the cursor position in the file, but can't figure out how to fix it.
Here's the code I'm using....
Thanks for any help you can give me.
Judy
Here's the code I'm using....
Code:
Dim objFSO, objTextFile
Dim sRead, sReadLine, sReadAll
Const ForReading = 1, ForWriting = 2, ForAppending = 8
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objTextFile = objFSO.OpenTextFile("D:\InetPub\[URL unfurl="true"]wwwMemotech\Docs\HowToDemoFile.txt",[/URL] ForWriting, True)
' Write a line with a newline character.
objTextFile.WriteLine("testing")
objTextFile.Close
Thanks for any help you can give me.
Judy