Beispiel #1
0
 /// <summary>
 /// Removes course from RegistrationDatabase
 /// </summary>
 /// <param name="courseID">Valid Course ID of a Course</param>
 public void RemoveCourse(string courseID)
 {
     if (this.GetStatus().Equals("manager"))
     {
         RegistrationDatabase.RemoveCourse(courseID);
     }
 }
Beispiel #2
0
        private void button8_Click(object sender, EventArgs e)
        {
            foreach (DataGridViewRow d_row in dataGridView1.Rows)
            {
                object ischecked = d_row.Cells[0].Value;

                if (ischecked == null)
                {
                }
                else
                {
                    try
                    {
                        RegistrationDatabase.RemoveCourse((string)d_row.Cells[2].Value);
                    }
                    catch
                    {
                        System.Windows.Forms.MessageBox.Show("Error in removing course");
                    }
                }
            }
            Form2_Load(sender, e);
        }