public static SurveyQuestion GetQuestion(this SurveyPage page, string name) { if (page.Questions == null) { return(null); } return(page.Questions.FirstOrDefault(q => q.QuestionName == name)); }
public static SurveyQuestion GetQuestionByText(this SurveyPage page, string question) { if (page.Questions == null) { return(null); } return(page.Questions.FirstOrDefault(q => q.QuestionText == question)); }
public static SurveyQuestion GetQuestionByID(this SurveyPage page, int id) { if (page.Questions == null) { return(null); } return(page.Questions.FirstOrDefault(q => q.SurveyQuestionID == id)); }