public void AddRequest(string pathToDB, AddRequestWindow wnd)
 {
     try
     {
         using (var sw = new StreamWriter(pathToDB, true))
         {
             sw.WriteLine(wnd.NumberOfRequestBox.Text + "|"
                          + wnd.TypeOfStreetBox.Text + " "
                          + wnd.StreetNameBox.Text + " "
                          + wnd.NumberOfHouseBox.Text + " "
                          + wnd.CityBox.Text + "|"
                          + wnd.TypeOfRequestBox.Text);
         }
     }
     catch (Exception ex)
     { MessageBox.Show(ex.Message); }
 }
Esempio n. 2
0
        private void AddRequestButton_Click(object sender, RoutedEventArgs e)
        {
            AddRequestWindow wnd = new AddRequestWindow();

            wnd.Show();
        }