Asp.net-mvc – how to redirect to aspx page in a controller action

asp.net-mvc

is it possible to redirect to an aspx page in an (asp.net-mvc3 )controller action?
What should be the return type of the action (ActionResult?) and which redirect method should be called (RedirectToAction?).

BR,

Best Answer

You can redirect to anywhere from MVC action and you have to use RedirectResult for that. RedirectResult is a type of ActionResult.

For ex.

public RedirectResult RedirectToAspx()
{
  return Redirect("/pages/index.aspx");
}