I am trying to make a Notepad in C#, but i am not able to save the file in *.txt format. However I am able to save the File using the below Code but is not saving it in *.txt Format. Please provide me the Appropriate Solution for this Problem.
str = saveFileDialog1.FileName;
saveFileDialog1.Title = "Save File";
saveFileDialog1.DefaultExt = "txt";
saveFileDialog1.ShowDialog();
saveFileDialog1.Filter = "Text Document(*.txt)|File Name(*txt)|All Files(*.*)|*.*";
richTextBox1.SaveFile(saveFileDialog1.FileName);
with advance thax,
Ramandeep Singh