Redirecting to another page on Session_end event

前端 未结 7 1405
心在旅途
心在旅途 2020-12-03 06:13

I would like to auto-redirect to login page when session time outs.

In web.config file, i have the following code


    

        
7条回答
  •  臣服心动
    2020-12-03 06:34

    I think you are getting "Response is not available in this context" because the user is not making a request to the server, and therefor you cannot provide it with a response. Try Server.Transfer instead.

提交回复
热议问题