Reading and Writing Text Files in C#

December 11, 2008 – 3:00 pm

This post was moved to:

http://codehill.com/2009/01/reading-and-writing-text-files-in-c/

Note: I moved all the programming posts to my other blog: CodeHill. As the name implies, CodeHill is dedicated to programming, please check it out and if you like it consider subscribing to the RSS feed. Sorry for the inconvenience.

  • Share/Bookmark
  1. 2 Responses to “Reading and Writing Text Files in C#”

  2. Well if you ever try to explore MSDN, you can check File.WriteAllText and File.ReadAllText does everything in one single line.

    By Akash Kava on Dec 12, 2008

  3. Hi Akash, thank you for the comment but WriteAllText and ReadAllText are available for Visual Basic only and to use them in C# you have to use Microsoft.VisualBasic. But the code above is not much when you remove the GUI stuff, like reading the file name from the OpenFileDialog control or clearing the TextBox.

    By Amgad Suliman on Dec 13, 2008

Post a Comment