Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private void tilaaNappi_Click(object sender, EventArgs e)
- {
- try
- {
- string maara;
- int value = (int)numericUpDown1.Value;
- maara = "" + (e95 + value);
- DialogResult result = MessageBox.Show("Oletko varma?", "Tilataan lisää", MessageBoxButtons.YesNo);
- if (result == DialogResult.Yes)
- {
- e95 = int.Parse(maara);
- using (StreamWriter sw = new StreamWriter(tiedostoPolku))
- {
- sw.WriteLine(e95);
- sw.WriteLine(e98);
- sw.WriteLine(diesel);
- this.Close();
- }
- }
- }
- catch
- {
- MessageBox.Show("Jotain meni pieleen");
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement