public ActionResult TestError() { var model = new TestErrorViewModel { IsCustomErrorsEnabled = ControllerContext.HttpContext.IsCustomErrorEnabled, IsCustomErrorsEnabledText = ControllerContext.HttpContext.IsCustomErrorEnabled ? "The defined custom error view will be rendered." : "To render the defined custom error, the httpErrors element needs to be set to Custom. eg. <httpErrors errorMode=\"Custom\"/>" }; return View(model); }
public ActionResult TestError() { var model = new TestErrorViewModel { IsCustomErrorsEnabled = ControllerContext.HttpContext.IsCustomErrorEnabled, IsCustomErrorsEnabledText = ControllerContext.HttpContext.IsCustomErrorEnabled ? "The defined custom error view will be rendered." : "To render the defined custom error, the httpErrors element needs to be set to Custom. eg. <httpErrors errorMode=\"Custom\"/>" }; return(View(model)); }