Exemple #1
0
        //上一步
        private void btnBefore_Click(object sender, EventArgs e)
        {
            QuestionTwo frmTwo = new QuestionTwo();

            frmTwo.TopMost = false;
            frmTwo.ShowDialog();
            Close();
        }
Exemple #2
0
        //下一步
        private void btnNext_Click(object sender, EventArgs e)
        {
            //第一题
            M_QuestionnaireResultDetail question1 = new M_QuestionnaireResultDetail();
            string strResult1 = "";

            if (crdb1A.Checked)
            {
                strResult1 = "A,";
            }
            if (crdb1B.Checked)
            {
                strResult1 = "B,";
            }
            if (crdb1C.Checked)
            {
                strResult1 = "C,";
            }
            if (crdb1D.Checked)
            {
                strResult1 = "D,";
            }
            if (crdb1E.Checked)
            {
                strResult1 = "E,";
            }

            question1.QuestionResult = strResult1;
            question1.QuestionCode   = QuestionnaireCode.KangFuShouShangZhi + ".1";
            question1.QuestionType   = 1;
            //打分


            ClientInfo.AddQuestionToQuestionnaire(question1, QuestionnaireCode.KangFuShouShangZhi);

            //第二题
            M_QuestionnaireResultDetail question2 = new M_QuestionnaireResultDetail();
            string strResult2 = "";

            if (crdb2A.Checked)
            {
                strResult2 = "A,";
            }
            if (crdb2B.Checked)
            {
                strResult2 = "B,";
            }
            if (crdb2C.Checked)
            {
                strResult2 = "C,";
            }
            if (crdb2D.Checked)
            {
                strResult2 = "D,";
            }
            if (crdb2E.Checked)
            {
                strResult2 = "E,";
            }

            question2.QuestionResult = strResult2;
            question2.QuestionCode   = QuestionnaireCode.KangFuShouShangZhi + ".2";
            question2.QuestionType   = 1;

            ClientInfo.AddQuestionToQuestionnaire(question2, QuestionnaireCode.KangFuShouShangZhi);

            //第三题
            M_QuestionnaireResultDetail question3 = new M_QuestionnaireResultDetail();
            string strResult3 = "";

            if (crdb3A.Checked)
            {
                strResult3 = "A,";
            }
            if (crdb3B.Checked)
            {
                strResult3 = "B,";
            }
            if (crdb3C.Checked)
            {
                strResult3 = "C,";
            }
            if (crdb3D.Checked)
            {
                strResult3 = "D,";
            }
            if (crdb3E.Checked)
            {
                strResult3 = "E,";
            }

            question3.QuestionResult = strResult3;
            question3.QuestionCode   = QuestionnaireCode.KangFuShouShangZhi + ".3";
            question3.QuestionType   = 1;

            ClientInfo.AddQuestionToQuestionnaire(question3, QuestionnaireCode.KangFuShouShangZhi);

            //第四题
            M_QuestionnaireResultDetail question4 = new M_QuestionnaireResultDetail();
            string strResult4 = "";

            if (crdb4A.Checked)
            {
                strResult4 = "A,";
            }
            if (crdb4B.Checked)
            {
                strResult4 = "B,";
            }
            if (crdb4C.Checked)
            {
                strResult4 = "C,";
            }
            if (crdb4D.Checked)
            {
                strResult4 = "D,";
            }
            if (crdb4E.Checked)
            {
                strResult4 = "E,";
            }

            question4.QuestionResult = strResult4;
            question4.QuestionCode   = QuestionnaireCode.KangFuShouShangZhi + ".4";
            question4.QuestionType   = 1;

            ClientInfo.AddQuestionToQuestionnaire(question4, QuestionnaireCode.KangFuShouShangZhi);

            //第五题
            M_QuestionnaireResultDetail question5 = new M_QuestionnaireResultDetail();
            string strResult5 = "";

            if (crdb5A.Checked)
            {
                strResult5 = "A,";
            }
            if (crdb5B.Checked)
            {
                strResult5 = "B,";
            }
            if (crdb5C.Checked)
            {
                strResult5 = "C,";
            }
            if (crdb5D.Checked)
            {
                strResult5 = "D,";
            }
            if (crdb5E.Checked)
            {
                strResult5 = "E,";
            }

            question5.QuestionResult = strResult5;
            question5.QuestionCode   = QuestionnaireCode.KangFuShouShangZhi + ".5";
            question5.QuestionType   = 1;

            ClientInfo.AddQuestionToQuestionnaire(question5, QuestionnaireCode.KangFuShouShangZhi);

            //第二页
            QuestionTwo frmTwo = new QuestionTwo();

            frmTwo.TopMost = false;
            frmTwo.ShowDialog();
            //frmTwo.Show();
            Close();
        }