I have a base controller class:
And all my other controller inherits this BaseClass like this
All this works great in MVC3 (test again today, it really works) but it seems that the ExecuteCore in BaseController is not fired any more in MVC 4 beta.
Any idea? Or Anything huge has changed under the hood? Thanks very much.
public class BaseController : Controller
{
private string _myData;
public string MyData
{
get
{
return _myData;
}
}
protected override void ExecuteCore()
{
_myData = "I am doing something";
base.ExecuteCore();
}
}
public class HomeController : BaseController
{
public ActionResult Index()
{
ViewBag.MyData = MyData;
// Doing something with value in BaseClass
return View();
}
}