Open pavelmatusyak opened 10 years ago
Hi. Yep, I had the same issue when I was trying to use MVCMailer with Umbraco. So if it has a workaround, that would be great to see so I can go back to using MVCMailer.
The responses in this issue led me to my solution:
var data = new RouteData();
data.DataTokens["playermailer"] = "PlayerMailer";
this.ControllerContext = new ControllerContext(context, data, this);
context
in this case is the HttpContext which is passed into the constructor. PlayerMailer
is the directory containing the views.
Glad I posted this for my future self as I just hit the problem again on an old site and uncovered this while looking for a solution! 😄
The responses in this issue led me to my solution:
var data = new RouteData(); data.DataTokens["playermailer"] = "PlayerMailer"; this.ControllerContext = new ControllerContext(context, data, this);
context
in this case is the HttpContext which is passed into the constructor.PlayerMailer
is the directory containing the views.
Glad I posted this for my future self as I just stumbled across it again while looking for the solution in an old site 😄
Hey,
I'm using with umbraco but I have following issue:
Here is my controller
And my Welcome method
My web config: