I have two textbox when I press a button textbox text save in a file, but when I again enter new text it is replace the previously saved text. My code:
using (StreamWriter strw = new StreamWriter("E:\\win part\\Discrete Mathematics\\userrequest.txt"))
{
strw.Write(nametextBox.Text+"\t");
strw.WriteLine(passwordtextBox.Text);
strw.Close();
MessageBox.Show("Yor request has been submitted successfully.", "Sucess", MessageBoxButtons.OK, MessageBoxIcon.Information);
}
I want to save this new text after previously saved text. please help me to solve this.