Tuesday, July 21, 2015

Asp.net: How to set session timeout using web.config

In this article I am going to explain how to set session timeout in Asp.net application using web.config

Description:

By default session timeout time is 20 minutes but in many cases we have to change (increase or decrease) the session time. In this example I am going to change the session timeout using web.config from 20 minute to 40 minute.

Open the web.config file and add the below given code to it.
<system.web>
  <sessionState timeout="40" mode="InProc" cookieless="false" ></sessionState>
</system.web>

  In this article we have learn How to set session timeout in Asp.net using web.configI hope you enjoyed this article. 

No comments:

Post a Comment