//update instructor
 private void update_button(object sender, EventArgs e)
 {
     try
     {
         string fname  = textBox1.Text;
         string lname  = textBox2.Text;
         int    insId  = (int)comboBox2.SelectedItem;
         int    deptId = (int)comboBox1.SelectedItem;
         using (Online_Exame ent = new Online_Exame())
         {
             ent.UpdateInstractor(insId, fname, lname, deptId);
             comboBox1.Text = comboBox2.Text = textBox1.Text = textBox2.Text = string.Empty;
             ent.SaveChanges();
             Loadinstructor();
         }
         MessageBox.Show("Updated Successfully");
     }
     catch (NullReferenceException)
     {
         MessageBox.Show("Not complete Form");
     }
 }