コード例 #1
0
        private void SaveorUpdateEvaluationbutton1_Click(object sender, EventArgs e)
        {
            Course aCourse = new Course();

            aCourse.CourseID = EvaluationCoursetextBox1.Text;

            StudentInformation aStudent = new StudentInformation();

            aStudent.StudentID       = EvaluationStudenIDtextBox3.Text;
            aStudent.Quiz1           = float.Parse(Quiz_1textBox12.Text);
            aStudent.Quiz2           = float.Parse(Quiz_2textBox10.Text);
            aStudent.Quiz3           = float.Parse(Quiz_3textBox14.Text);
            aStudent.QUIZ            = float.Parse(QUIZ_textBox9.Text);
            aStudent.Assignment      = float.Parse(AssignmenttextBox4.Text);
            aStudent.Attendance      = float.Parse(Attendance_textBox8.Text);
            aStudent.Presentation    = float.Parse(PresentationtextBox7.Text);
            aStudent.Mid             = float.Parse(MidtermtextBox5.Text);
            aStudent.Final           = float.Parse(FinaltextBox6.Text);
            aStudent.Total           = float.Parse(TotalMarkstextBox13.Text);
            aStudent.EvaluationGrade = EvaluationGrade.Text;

            StudentInformationBLL aStudents = new StudentInformationBLL();
            bool res = aStudents.SaveEvaluationBLL(aStudent, aCourse);

            if (res)
            {
                MessageBox.Show("Marks Evaluated Successfully!!!");
                clearCourseTextBoxes();
                LoadCoursesDataGridView();
            }
            else
            {
                MessageBox.Show("Error!");
            }
        }
コード例 #2
0
        private void EvaluationdataGridView1_CellMouseClick(object sender, DataGridViewCellMouseEventArgs e)
        {
            string             Details  = Evaluation_CourseDetailscomboBox1.Text;
            StudentInformation aStudent = new StudentInformation();

            aStudent.StudentID = EvaluationdataGridView1.SelectedRows[0].Cells[0].Value.ToString();
            aStudent.CID       = EvaluationdataGridView1.SelectedRows[0].Cells[2].Value.ToString();

            StudentInformationBLL aStudents = new StudentInformationBLL();
            DataTable             dt2       = aStudents.EvaluationInformationInTextboxBLL(aStudent, Details);

            try
            {
                EvaluationCoursetextBox1.Text       = dt2.Rows[0][16].ToString();
                Evaluation_StudentNametextBox2.Text = dt2.Rows[0][3].ToString();
                EvaluationStudenIDtextBox3.Text     = dt2.Rows[0][2].ToString();

                Quiz_1textBox12.Text      = dt2.Rows[0][7].ToString();
                Quiz_2textBox10.Text      = dt2.Rows[0][8].ToString();
                Quiz_3textBox14.Text      = dt2.Rows[0][9].ToString();
                QUIZ_textBox9.Text        = dt2.Rows[0][10].ToString();
                Attendance_textBox8.Text  = dt2.Rows[0][4].ToString();
                AssignmenttextBox4.Text   = dt2.Rows[0][6].ToString();
                MidtermtextBox5.Text      = dt2.Rows[0][11].ToString();
                FinaltextBox6.Text        = dt2.Rows[0][12].ToString();
                PresentationtextBox7.Text = dt2.Rows[0][5].ToString();
                TotalMarkstextBox13.Text  = dt2.Rows[0][13].ToString();
                EvaluationGrade.Text      = dt2.Rows[0][14].ToString();
            }
            catch
            {
                MessageBox.Show("dufgy");
            }
        }
コード例 #3
0
        public void LoadEvaluationStudentInformation()
        {
            string Details = Evaluation_CourseDetailscomboBox1.Text;
            StudentInformationBLL aStudent = new StudentInformationBLL();
            DataTable             dt2      = aStudent.ViewStudentInformationBLL(Details);

            EvaluationdataGridView1.DataSource = dt2;
        }
コード例 #4
0
        public void LoadStudentInformation()
        {
            string Details = SelectCourse_comboBox1.Text;
            StudentInformationBLL aStudent = new StudentInformationBLL();
            DataTable             dt2      = aStudent.ViewStudentInformationBLL(Details);

            StudentInformationdataGridView1.DataSource = dt2;
        }
コード例 #5
0
        private void evaluationToolStripMenuItem_Click(object sender, EventArgs e)
        {
            ClearComboBox();
            COURSEpanel3.Visible = false;
            StudentInformation_panel3.Visible = false;
            Evaluation_panel3.Visible         = true;
            StudentInformationBLL aStudent = new StudentInformationBLL();
            DataTable             dt       = aStudent.LoadComboboxBLL();

            for (int i = 0; i < dt.Rows.Count; i++)
            {
                Evaluation_CourseDetailscomboBox1.Items.Add(dt.Rows[i][0]);
            }
        }
コード例 #6
0
        private void StudentDeletebutton3_Click(object sender, EventArgs e)
        {
            string             Details  = SelectCourse_comboBox1.Text;
            StudentInformation aStudent = new StudentInformation();

            aStudent.StudentID = StudentIDtextBox2.Text;
            aStudent.name      = StudentNAmetextBox1.Text;
            StudentInformationBLL aStudents = new StudentInformationBLL();
            bool res = aStudents.DeleteStudentBLL(aStudent, Details);

            if (res)
            {
                MessageBox.Show("Student Information Deleted Successfully!!!");
                LoadStudentInformation();
                StudentIDtextBox2.Text   = "";
                StudentNAmetextBox1.Text = "";
            }
            else
            {
                MessageBox.Show("Error!");
            }
        }