
Which is the Best Way To Edit a Text File
NumLock,
I would use the FileStream class to create the underlying stream, and
then use a StreamWriter class to write the text. Just make sure that you
are using the correct encoding when you write to the underlying stream.
Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
Quote:
> Hi All,
> Which is the best method of editing a text file using System.IO ?
> I want to edit some existing lines in it and save.
> TIA,
> NumLock