a blog for those who code

Sunday 29 June 2014

Set Session timeout in Asp.Net

In this post we will show you how to set new session timeout in Asp.Net. The default session timeout of asp.net website in 20 min. Now if you want to increase that time, you can do using the following code.

First Method is to add in web.config.

<sessionState mode="InProc" timeout="1200">

Second Method is to add in global.asax

void Session_Start(object sender, EventArgs e)
Session.Timeout = 200;

Please Like and Share the Blog, if you find it interesting and helpful.

No comments:

Post a Comment