-1

Hi guys.. Can anybody tell me about how to increment default session timeout(20 mins) in dot net..? It's urgent.. Hope anybody will help me.. Thanks in advance...

4
Contributors
7
Replies
9
Views
6 Years
Discussion Span
Last Post by Dragonbaki
-1

I have given like this in web.config file.. But still it doesn't work..?

<system.web>
    <sessionState timeout="200"></sessionState>
0

Any particular reason you want to set the timeout to an arbitary value of 200 or do you just want the session variables to remain indefinately?

If its indefinately then check that the user has been authenticated and populate the session variables accordingly

-1

Text from MSDN Page :

The Timeout property cannot be set to a value greater than 525,600 minutes (1 year). The default value is 20 minutes.

The following code example sets the timeout session attribute to 30 minutes in the Web.config file.

<configuration>
  <system.web>
    <sessionState 
      mode="InProc"
      cookieless="true"
      timeout="30" />
  </system.web>
</configuration>

You can override this setting programatically:

Session.TimeOut=50;

Edited by __avd: n/a

-1

If you manage IIS, the very simple to increasing time of session in there, all set time in code behide or webconfig are not change. Hope it help you

-1

When i gave like this..

<system.web> <sessionState timeout="200"></sessionState><system.web>
<sessionState timeout="200"></sessionState>

its working fine... Thanks..

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.