public IActionResult Delete(int?Id) { var question = _Question.GetQuestion(Id); if (question == null) { return(RedirectToAction("Index")); } dynamic models = new ExpandoObject(); models.Question = question; models.Options = _Option.GetOptionsByQuestionId(Id); return(View(models)); }