bool CheckHoursTextBox()
 {
     if (WelcomePage.IsNumber(HoursTextBox.Text) == false)
     {
         MessageBox.Show("The hours textbox can only contain integer numbers.");
         return(false);
     }
     else if (int.Parse(HoursTextBox.Text) > 6)
     {
         MessageBox.Show("The hours cannot exceed 6 hours.");
         return(false);
     }
     return(true);
 }
 bool CheckGradesTextBoxes()
 {
     if (WelcomePage.IsNumber(CourseGradeTextBox.Text) == false)
     {
         MessageBox.Show("The textbox of course grade must have only integer numbers.");
         return(false);
     }
     else if (WelcomePage.IsNumber(PassingGradeTextBox.Text) == false)
     {
         MessageBox.Show("The textbox of passing grade must have only integer numbers.");
         return(false);
     }
     else if (int.Parse(PassingGradeTextBox.Text) >= int.Parse(CourseGradeTextBox.Text))
     {
         MessageBox.Show("Passing grade of course cannot exceed the course grade.");
         return(false);
     }
     else if (int.Parse(CourseGradeTextBox.Text) > 200)
     {
         MessageBox.Show("Course grade cannot exceed 200.");
         return(false);
     }
     return(true);
 }
 bool CheckNumberOfStudentsTextBoxes()
 {
     if (WelcomePage.IsNumber(CurrentNumberOfStudentsTextBox.Text) == false)
     {
         MessageBox.Show("Textbox of current number of students must have only integer numbers.");
         return(false);
     }
     else if (WelcomePage.IsNumber(MaximumNumberOfStudentsTextBox.Text) == false)
     {
         MessageBox.Show("Textbox of maximum number of students must have only integer numbers.");
         return(false);
     }
     else if (int.Parse(MaximumNumberOfStudentsTextBox.Text) < int.Parse(CurrentNumberOfStudentsTextBox.Text))
     {
         MessageBox.Show("The current number of students in this course exceeds the maximum number.");
         return(false);
     }
     else if (int.Parse(MaximumNumberOfStudentsTextBox.Text) > 500)
     {
         MessageBox.Show("The maximum number of students in class cannot exceed 500 students.");
         return(false);
     }
     return(true);
 }