Skip to content

Instantly share code, notes, and snippets.

@droyad
Created May 2, 2012 11:18
Show Gist options
  • Save droyad/2575910 to your computer and use it in GitHub Desktop.
Save droyad/2575910 to your computer and use it in GitHub Desktop.
using (Stream stream = new FileStream("file.txt", FileMode.OpenOrCreate))
{
using (StreamWriter writer = new StreamWriter(stream))
{
// Use the writer object...
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment