S
Selden McCabe
I'm using the following code to write some text to a file:
objWriter = New StreamWriter(FullPath, True, System.Text.Encoding.ASCII)
For nRow = 1 To sData.Length - 1
objWriter.WriteLine(sData(nRow))
Next nRow
objWriter.Flush()
objWriter.Close()
When I run this in the IDE, it works. When I compile it and run the EXE, it
doesn't give any errors, but it doesn't create the file either. I've tried
putting a message box in the loop, and the data is acutally there. I've put
this in a try/catch block, but it doesn't catch any error.
I've tried creating a setup package, building it, then running the setup.
Same behavior.
I've also tried just objWriter = New StreamWriter(FullPath), same behavior.
What am I doing wrong? Any ideas or suggestions at all would be
appreciated!
Thanks,
---Selden McCabe
objWriter = New StreamWriter(FullPath, True, System.Text.Encoding.ASCII)
For nRow = 1 To sData.Length - 1
objWriter.WriteLine(sData(nRow))
Next nRow
objWriter.Flush()
objWriter.Close()
When I run this in the IDE, it works. When I compile it and run the EXE, it
doesn't give any errors, but it doesn't create the file either. I've tried
putting a message box in the loop, and the data is acutally there. I've put
this in a try/catch block, but it doesn't catch any error.
I've tried creating a setup package, building it, then running the setup.
Same behavior.
I've also tried just objWriter = New StreamWriter(FullPath), same behavior.
What am I doing wrong? Any ideas or suggestions at all would be
appreciated!
Thanks,
---Selden McCabe