c# - Call method every time a controller method is ending -


i have static class called notificationmanager , every time controller method called, want store modelerrors in notificationmanager.

however, inside notificationmanager, can't access modelstate because not inside actual controller.

is there way automatically call method once controller method finished, without having write in every single controller method?

note: need use values in view.

override onactionexecuted in controller. still have viewdata[]

protected override void onactionexecuted(actionexecutedcontext filtercontext) {     //do stuff     base.onactionexecuted(filtercontext); } 

Comments

Popular posts from this blog

plot - Remove Objects from Legend When You Have Also Used Fit, Matlab -

java - Why does my date parsing return a weird date? -

Need help in packaging app using TideSDK on Windows -