| | |
StreamWriter Is Overriding Already Written Items in File
Please support our VB.NET advertiser: Intel Parallel Studio Home
Thread Solved |
•
•
Join Date: Jul 2008
Posts: 86
Reputation:
Solved Threads: 0
Hello everyone. I have a small problem. I have a Streamwriter writing things to a file. But when i write more than one thing, the previous item gets overwritten. I.E. Write 1111, Write 2222. 1111 gets replaced by 2222.
Here is some of my code:
userId is a String
Here is some of my code:
VB.NET Syntax (Toggle Plain Text)
Dim fileOut As New IO.StreamWriter(fileName) fileOut.WriteLine(userId) fileOut.Close()
userId is a String
You have to create StreamWriter in the append mode
VB.NET Syntax (Toggle Plain Text)
Dim fileOut As New System.IO.StreamWriter(fileName, True)
Teme64 @ Windows Developer Blog
It appends now? Great. Please mark the thread solved and re-post that new question in a new thread, thanks.
Teme64 @ Windows Developer Blog
![]() |
Other Threads in the VB.NET Forum
- Previous Thread: Howto: Pan and Zoom an image in the picture box in vb.net?
- Next Thread: Multi Column List Boxes
| Thread Tools | Search this Thread |
.net .net2008 2005 2008 access account arithmetic array arrays basic bing button buttons c# center check checkbox code convert crystalreport data database datagrid datagridview date dissertation dissertations dropdownlist excel fade file-dialog filter ftp generatetags google gridview hardcopy images inline input insert intel internet listview mobile monitor ms net networking objects output panel passingparameters picturebox picturebox1 port position print printing problem project read remove save searchbox searchvb.net select serial server shutdown soap sorting survey table tcp temperature text textbox timer timespan toolbox trim update user validation vb vb.net vb.netformclosing()eventpictureboxmessagebox vb2008 vbnet view visual visualbasic visualbasic.net visualstudio visualstudio2008 web winforms wpf year





