private void sendSelectSQL()
 {
     try
     {
         parentForm.SetSqlCommand(sqlDeleteCreator.ToString());
         this.Close();
     }
     catch (SqlException ex)
     {
         MessageBox.Show(ex.ToString());
     }
     catch (InvalidOperationException ex)
     {
         if (MainForm.builder.ToString() == "")
         {
             MessageBox.Show("Date de logare incorecte!");
         }
         else
         {
             MessageBox.Show(ex.ToString());
         }
     }
 }
Exemple #2
0
 private void sendSelectSQL()
 {
     try
     {
         parentForm.SetSqlCommand(sqlSelectCreator.ToString());
         this.Close();
     }
     catch (SqlException sqlEx)
     {
         MessageBox.Show(sqlEx.ToString());
     }
     catch (InvalidOperationException ex)
     {
         if (MainForm.builder.ToString() == "")
         {
             MessageBox.Show("Incorrect login data.");
             //startLoginForm();
         }
         else
         {
             MessageBox.Show(ex.ToString());
         }
     }
 }