Exemplo n.º 1
0
        //Посмотреть свои результаты
        private void ViewResultsTSMI_Click(object sender, EventArgs e)
        {
            string s;

            if (FindResultBox.Input(out s))
            {
                XML_USER xmlUser = new XML_USER();
                xmlUser.DeSerialize(s);
                ResultForm.ShowForm(xmlUser);
                this.Hide();
            }
        }
Exemplo n.º 2
0
        //Считывание ответа пользователя
        private void PushButton_Click(object sender, EventArgs e)
        {
            List <string> UserAnswer = UsAnswer();
            int           point      = CalculationPoint(UserAnswer);

            if (UserAnswer.Count != 0)
            {
                xmlUser.Questions.Add(new Question(XmlTest.Questions[K].question, point, XmlTest.Questions[K].Type, XmlTest.Questions[K].TrueAnswer, UserAnswer));
            }
            K++;
            if (K == XmlTest.Questions.Count)
            {
                CreateUserXML();
                this.Dispose();
                ResultForm.ShowForm(xmlUser);
                return;
            }
            QuestionGB.Controls.Clear();
            Get_Question();
        }