Ejemplo n.º 1
0
        /** Called when the "True" button is clicked. */
        private void button1_Click(object sender, EventArgs e)
        {
            String theAnswer = theQuiz.GetAnswer().ToLower();

            if (theAnswer.Equals("true"))
            {
                theQuiz.AddCorrect();
            }
            else if (theAnswer.Equals("false"))
            {
                theQuiz.AddIncorrect();
            }
            // print out the results to the user
            quiz_notification_label.Text = "Correct: " + theQuiz.NumberCorrect + ", Incorrect: " + theQuiz.NumberIncorrect;
            quiz_notification_label.Text = theQuiz.GetQuestion();
        }