Esempio n. 1
0
        private void BtnEditProfile_Click(object sender, EventArgs e)
        {
            EditStudent edit = new EditStudent
            {
                studentID = this.UserID
            };

            edit.ShowDialog();
        }
Esempio n. 2
0
 private void BtnEditStudent_Click(object sender, EventArgs e)
 {
     try
     {
         if (selectedStudent != 0)
         {
             EditStudent editStudentForm = new EditStudent
             {
                 studentID = selectedStudent.ToString()
             };
             editStudentForm.ShowDialog();
             PopulateGridView();
             connection.Close();
         }
         else
         {
             MessageBox.Show("Please select a student");
         }
     }
     catch (Exception error)
     {
         MessageBox.Show("Error: " + error.Message);
     }
 }