I am trying to save a number of different forms to a text file, currently I have:
- Temperature
- Wind
- Rain
- Cloud
The issue that I'm having is that it only saves the "Cloud" data. Is there a way I can save all the information on submission and have them separated by a comma, dash, or just a space?
This is the code I'm currently using:
private void button2_Click(object sender, RoutedEventArgs e)
{
File.WriteAllText("C:\\WeatherSpotter.txt", tempC.Text);
File.WriteAllText("C:\\WeatherSpotter.txt", tempF.Text);
File.WriteAllText("C:\\WeatherSpotter.txt", windMPH.Text);
File.WriteAllText("C:\\WeatherSpotter.txt", windKM_Textbox.Text);
File.WriteAllText("C:\\WeatherSpotter.txt", Cloud_ComboBox.Text);
}