I have been looking through trying to find some way to redirect to an Index
view from another controller.
public ActionResult Index()
{
ApplicationController viewModel = new ApplicationController();
return RedirectToAction("Index", viewModel);
}
This is what I tried right now. Now the code I was given to has a ActionLink
that links to the page I need to Redirect
too.
@Html.ActionLink("Bally Applications","../Application")
Use the overloads that take the controller name too...
return RedirectToAction("Index", "MyController");
and
@Html.ActionLink("Link Name","Index", "MyController", null, null)