I have a window which has two textboxes namely Username and Password and two buttons namely Save and Close. I want to create a .txt file when the save button is clicked.The name of the text file should be the Username and have details of username and password in it. So every time when I save with a different Username it creates a text file with the username as file name.
string fileName = textBox1.Text + ".txt";
File.Create("C:\\Users\\User\\Documents\\1ClickData\\ID\\fileName.txt");
The above code is not working for me. Please help.
Also the textboxes are transparent. I don't want them to be transparent. Please help me out in this also. Thank you.