// Set the properties on SaveFileDialog1 so the user is
// prompted to create the file if it doesn't exist
// or overwrite the file if it does exist.
SaveFileDialog1.CreatePrompt = true;
SaveFileDialog1.OverwritePrompt = true;
// Set the file name to myText.txt, set the type filter
// to text files, and set the initial directory to drive C.
SaveFileDialog1.FileName = "myText";
SaveFileDialog1.DefaultExt = "txt";
SaveFileDialog1.Filter = "Text files (*.txt)|*.txt";
SaveFileDialog1.InitialDirectory = "c:\\";