Write string to a text file : Text File Read Write « File Stream « C# / C Sharp
- C# / C Sharp
- File Stream
- Text File Read Write
Write string to a text file
using System;
using System.Data;
using System.IO;
class Class1{
static void Main(string[] args){
StreamWriter sw = new StreamWriter("practice.txt");
sw.Write("www.java2s.com");
sw.Close();
}
}
Related examples in the same category