private void Button_Click(object sender, RoutedEventArgs e)
 {
     try
     {
         PrintInvoice newInvo = new PrintInvoice(Int32.Parse(txtInoD.Text.ToString()));
         newInvo.Show();
     }
     catch
     {
         MessageBox.Show("Please insert Invoice Number! ", "Warning", MessageBoxButton.OK, MessageBoxImage.Warning);
     }
 }
Beispiel #2
0
        private void Button_Click_1(object sender, RoutedEventArgs e)
        {
            try
            {
                mycli.insertSalse(billNO, totalBill, s);

                PrintInvoice newInvo = new PrintInvoice(billNO);
                newInvo.Show();
            }

            catch
            {
                MessageBox.Show("please at least one item to generate report!");
            }
        }