private void DisplayAnswers(Question question_object) { for (int i = 0; i < answer_containers.Length; i++) { answer_containers[i].Text = question_object.GetAnswer(i); answer_containers[i].option = i; } RandAnswers(); }
public CheckQuestionItem(Question userQuestion, Question goodQuestion) { InitializeComponent(); QuestionNumberLabel.Content = $"{userQuestion.ID + 1}. kérdés"; QuestionNameTextBlock.Text = userQuestion.Name; for (int i = 0; i < userQuestion.Answers.Count; i++) { Answer user = userQuestion.Answers[i]; AnswersStackPanel.Children.Add(new CheckAnswerItem(user, goodQuestion.GetAnswer(user.ID))); } }
public void DisplayObject(Question question_object) { switch (display_type) { case DisplayType.Hint: Display(question_object.GetHint(Random.Range(0, question_object.HintCount))); break; case DisplayType.Answer: Display(question_object.GetAnswer(0)); break; case DisplayType.Question: Display(question_object.Text); break; case DisplayType.Subject: Display(question_object.Subject); break; } //hint_text.Display (question_object.GetHint(Random.Range (0,question_object.HintCount))); // answer_text.Display (question_object.GetAnswer(0)); // subject_text.Display (question_object.Subjects.ToArray()); }