How to redirect to particular view in Session_End method in Global.asax using asp.net
I tried using Response.Redirect("~/Home/Index") but it is giv开发者_高级运维ing error like "Response is unrecognized in Global.asax".
You can't do this. Session_End could be fired without an actual HTTP context. The user might have even closed his browser long before this event gets fired so there is nowhere to redirect to. The Request and Response objects are not available.
Conclusion: don't do this.
精彩评论