Exemplo n.º 1
0
        private void btnBefore_Click(object sender, EventArgs e)
        {
            QuestionThree frmBefore = new QuestionThree();

            frmBefore.TopMost = false;
            frmBefore.ShowDialog();
            this.Close();
        }
Exemplo n.º 2
0
        private void btnNext_Click(object sender, EventArgs e)
        {
            M_QuestionnaireResultDetail question1 = new M_QuestionnaireResultDetail();

            if (rd1A.Checked)
            {
                question1.QuestionResult = "A";
            }
            if (rd1B.Checked)
            {
                question1.QuestionResult = "B";
            }
            if (rd1C.Checked)
            {
                question1.QuestionResult = "C";
            }

            AddResult(question1, QuestionnaireCode.NaoCuZhong + ".2", 1);

            M_QuestionnaireResultDetail question2 = new M_QuestionnaireResultDetail();

            //question2.QuestionResult = dtpConfirm.Value.ToString();
            question2.QuestionResult = cbxYear.Text + "/" + cbxMonth.Text + "/" + cbxDay.Text + " " + DateTime.Now.TimeOfDay;
            AddResult(question2, QuestionnaireCode.NaoCuZhong + ".2.1", 3);


            M_QuestionnaireResultDetail question3 = new M_QuestionnaireResultDetail();

            if (chkA.Checked)
            {
                question3.QuestionResult += "A,";
            }
            if (chkB.Checked)
            {
                question3.QuestionResult += "B,";
            }
            if (chkC.Checked)
            {
                question3.QuestionResult += "C,";
            }

            AddResult(question3, QuestionnaireCode.NaoCuZhong + ".2.2", 1);

            M_QuestionnaireResultDetail question4 = new M_QuestionnaireResultDetail();

            if (rd2A.Checked)
            {
                question4.QuestionResult = "A,";
            }
            if (rd2B.Checked)
            {
                question4.QuestionResult = "B,";
            }

            AddResult(question4, QuestionnaireCode.NaoCuZhong + ".2.3", 3);

            M_QuestionnaireResultDetail question5 = new M_QuestionnaireResultDetail();

            question5.QuestionResult = txt24.Text;
            AddResult(question5, QuestionnaireCode.NaoCuZhong + ".2.4", 3);

            M_QuestionnaireResultDetail question6 = new M_QuestionnaireResultDetail();

            question6.QuestionResult = txt25.Text;
            AddResult(question6, QuestionnaireCode.NaoCuZhong + ".2.5", 3);

            M_QuestionnaireResultDetail question7 = new M_QuestionnaireResultDetail();

            question7.QuestionResult = txt26.Text;
            AddResult(question7, QuestionnaireCode.NaoCuZhong + ".2.6", 3);

            M_QuestionnaireResultDetail question8 = new M_QuestionnaireResultDetail();

            question8.QuestionResult = txt27.Text;
            AddResult(question8, QuestionnaireCode.NaoCuZhong + ".2.7", 3);

            QuestionThree frmNext = new QuestionThree();

            frmNext.TopMost = false;
            frmNext.ShowDialog();
            this.Close();
        }