****UPDATED****
I have a custom ContentActionInvoker that has some crazy logic in it.
I’d like in some case to invoke a different action in a diffrent controller and with some different parameters.
How can this be done?
class ContentActionInvoker : ControllerActionInvoker
{
protected override ActionResult InvokeActionMethod(ControllerContext controllerContext, ActionDescriptor actionDescriptor, IDictionary<string, object> parameters)
{
....
}
}
Why do you need to redirect the user’s experience back through the webserver (forcing the browser to make a round-trip) to access another class that is operating in the same AppDomain as the code that received the request from the MvcHandler?
If you want process data in another method, with different parameters, just instantiate that other class (or controller, which is just another class…) and either return the ActionResult generated by THOSE methods, or reformat your own ActionResult for the View requested.