Exemple #1
0
        private void btnBefore_Click(object sender, EventArgs e)
        {
            //停止播放
            if (wmPlayerForm != null)
            {
                wmPlayerForm.Stop();
            }

            QuestionFour frmBefore = new QuestionFour();

            frmBefore.TopMost = false;
            frmBefore.Show();
            this.Close();
        }
Exemple #2
0
        private void btnNext_Click(object sender, EventArgs e)
        {
            //停止播放
            if (wmPlayerForm != null)
            {
                wmPlayerForm.Stop();
            }

            string strResult = "";

            if (chkA.Checked)
            {
                strResult += "A,";
            }

            if (chkB.Checked)
            {
                strResult += "B,";
            }

            if (chkC.Checked)
            {
                strResult += "C,";
            }

            if (chkD.Checked)
            {
                strResult += "D,";
            }

            if (chkE.Checked)
            {
                strResult += "E,";
            }

            M_QuestionnaireResultDetail question1 = new M_QuestionnaireResultDetail();

            question1.QuestionResult = strResult;

            question1.QuestionCode  = QuestionnaireCode.NaoNianChiDai + ".3";
            question1.QuestionType  = 2;
            question1.PQuestionCode = QuestionnaireCode.NaoNianChiDai + ".3";
            //第三题,每答对一项记1分,共5分,权重1.8
            int tempScore = 0;

            if (strResult.Contains("A"))
            {
                tempScore += 1;
            }

            if (strResult.Contains("B"))
            {
                tempScore += 1;
            }

            if (strResult.Contains("C"))
            {
                tempScore += 1;
            }

            if (strResult.Contains("D"))
            {
                tempScore += 1;
            }

            if (strResult.Contains("E"))
            {
                tempScore += 1;
            }

            question1.QuestionScore        = tempScore;
            question1.PQuestionWeightScore = (decimal)(tempScore * 1.8);

            ClientInfo.AddQuestionToQuestionnaire(question1, QuestionnaireCode.NaoNianChiDai);

            QuestionFour form = new QuestionFour();

            form.TopMost = false;
            //form.Show();
            form.Show();
            this.Close();
        }