I’m familiar with using a HttpModule to time requests but those don’t really hook into ASP.NET MVC’s view system. Can this be done by starting a timer somewhere in global.asax and then accessing it in _layout.cshtml?
I’m familiar with using a HttpModule to time requests but those don’t really hook
Share
1) You can check the start time and end time of a request in Begin_Request and End_Request events of application class
2) You can define a custom HttpModule
3)You can define a custom attribute as follows: