Esempio n. 1
0
 private void button2_Click(object sender, EventArgs e)
 {
     try
     {
         int    studentId = Convert.ToInt32(lblstudentId.Text);
         string message   = StudentController.DeleteStudents(studentId);
         MessageBox.Show(message);
         loadgrid();
         clear();
     }
     catch (FormatException fe)
     {
         MessageBox.Show("please select a specific lecturer");
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }