I'm interested in Redirect of reference action post And I want it to be similar to the generic
ActionResult action = new DashboardController().Index(3);
return action;
i wants code like this
Because I redirect to a page using the POST I can't using this
return RedirectToAction(actionName, controllerName);
public ActionResult generic(string Controller,string Action)
{
Assembly asm = Assembly.GetAssembly(typeof(MvcApplication));
var controlleractionlist = asm.GetTypes()
.Where(type => typeof(Controller).IsAssignableFrom(type));
return typeof(typeof(controlleractionlist).GetProperty(Controller))
.GetProperty(Action);
}
Links can help Perhaps the answer Link 1 link 2
I apologize in advance for my English