In ASP.NET the method that sets the expiration time of Session

  • 2020-05-19 04:30:53
  • OfStack

Method 1:

Set Session.Timeout = 1;

Note: 1. This method can be set on a public page and called directly.

2. Time is measured in minutes

Method 2:

Set in Web.config:

in < system.web > < /system.web > writes < sessionState mode="InProc" timeout="1" / >


Related articles: