Exemplo n.º 1
0
        private void btnRank_Click(object sender, EventArgs e)
        {
            if (SemesterScores.Count <= 0)
            {
                MsgBox.Show("無任何成績資料可排名。");
                return; //沒有任何學期成績不進行排名。
            }
            if (!Sems.ValidateControlContent())
            {
                return;                                   //學期資訊不正確不進行排名。
            }
            if (!ValidateTopRankText())
            {
                return;
            }
            if (!ValidatePercentageText())
            {
                return;
            }
            if (!ValidateDataGrid())
            {
                return;
            }

            RefreshSelectedSubjects();
            if (SelectedSubjects.Count <= 0)
            {
                return;
            }

            RatingUtils.DisableControls(this);
            PrepareData();
        }
Exemplo n.º 2
0
        private void btnRank_Click(object sender, EventArgs e)
        {
            if (SemesterScores.Count <= 0)
            {
                MsgBox.Show("無任何成績資料可排名。");
                return; //沒有任何學期成績不進行排名。
            }
            if (!ValidateDataGrid())
            {
                return;
            }

            RefreshSelectedSubjects();
            if (SelectedSubjects.Count <= 0)
            {
                return;
            }

            RefreshSelectedTokens();
            if (Tokens.Count <= 0)
            {
                MsgBox.Show("請選擇至少一個學期來進行排名。");
                return;
            }

            RatingUtils.DisableControls(this);
            PrepareData();
        }
Exemplo n.º 3
0
        private void FormSemestersSubject_Load(object sender, EventArgs e)
        {
            //if (Site.DesignMode) return;

            RatingUtils.DisableControls(this);
            RefreshSubjectOptions();
            RatingUtils.EnableControls(this);
        }
Exemplo n.º 4
0
        private void FormSemesterSubject_Load(object sender, EventArgs e)
        {
            //if (Site.DesignMode) return;

            RatingUtils.DisableControls(this);
            RatingUtils.SetSemesterDefaultItems(cboSchoolYear, cboSemester);
            Sems = new SemesterSelector(cboSchoolYear, cboSemester);
            Sems.SemesterChanged += new EventHandler(Sems_SemesterChanged);
            RefreshSubjectOptions();
            RatingUtils.EnableControls(this);
        }
Exemplo n.º 5
0
        private void FormExamSubject_Load(object sender, EventArgs e)
        {
            //if (Site.DesignMode) return;

            RatingUtils.DisableControls(this);
            RatingUtils.SetSemesterDefaultItems(cboSchoolYear, cboSemester);
            Sems = new SemesterSelector(cboSchoolYear, cboSemester);
            Sems.SemesterChanged += new EventHandler(Sems_SemesterChanged);
            FillDomainOptions();
            FillCurrentSemesterData(); //準備目前學年度學期需要的資料。
            RatingUtils.EnableControls(this);
        }
Exemplo n.º 6
0
        private void FormExamSubject_Load(object sender, EventArgs e)
        {
            //if (Site.DesignMode) return;

            RatingUtils.DisableControls(this);
            RatingUtils.SetSemesterDefaultItems(cboSchoolYear, cboSemester);
            RatingUtils.SetExamDefaultItems(cboExam);
            Sems = new SemesterSelector(cboSchoolYear, cboSemester);
            Sems.SemesterChanged += new EventHandler(Sems_SemesterChanged);
            IncludeQuery          = new AEIncludeQuery();

            if (cboExam.Items.Count > 0)
            {
                cboExam.SelectedIndex = 0;
            }

            RatingUtils.EnableControls(this);
        }
Exemplo n.º 7
0
        private void btnRank_Click(object sender, EventArgs e)
        {
            if (Courses.Count <= 0)
            {
                MsgBox.Show("無任何成績資料可排名。");
                return; //沒有課程資料就不排名了。
            }
            if (!Sems.ValidateControlContent())
            {
                return;                                   //學期資訊不正確不進行排名。
            }
            if (!ValidateExamControl())
            {
                return;                           //試別資訊不正確不進行排名。
            }
            if (!ValidateTopRankText())
            {
                return;
            }
            if (!ValidatePercentageText())
            {
                return;
            }
            if (!ValidateDataGrid())
            {
                return;
            }

            RefreshSelectedDomains();
            if (SelectedDomains.Count <= 0)
            {
                return;
            }

            RatingUtils.DisableControls(this);
            PrepareData();
        }
Exemplo n.º 8
0
 private void FormGraduation_Load(object sender, EventArgs e)
 {
     RatingUtils.DisableControls(this);
     RatingUtils.EnableControls(this);
 }