I am creating a free interface and would like to call the code below my controller ...
return RedirectToAction("Activity");
How do I create this method? I have:
public FluentCommand RedirectOnSuccess(string url) { if (IsSuccess) ;
Note. IsSuccess is installed here:
public FluentCommand Execute() { try { _command.Execute(); IsSuccess = true; } catch (RulesException ex) { ex.CopyTo(_ms); IsSuccess = false; } return this; }
I call my free interface:
var fluent = new FluentCommand(new UpdateCommand(param,controller,modelstate) .Execute() .RedirectOnSucess("Actionname");
source share