Click here to Skip to main content
15,898,373 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i have set session timeout in web.config but session expires automatically while i am working.
is there any way to set sesssion timeout
//web.config

XML
<authentication mode="Forms">
     <forms  loginUrl="~/Home/Login" timeout="30"  />
   </authentication>

 <sessionState  timeout="30"></sessionState>
Posted
Updated 28-Mar-14 20:42pm
v3

C#
<configuration>
  <system.web>
    <sessionstate>
      mode="InProc"
      cookieless="true"
      timeout="30" />
  </sessionstate></system.web>
</configuration>


if set timeout property as 30 .the session will be expires after 30 minutes.
 
Share this answer
 
Comments
Member 9579525 29-Mar-14 2:57am    
this also not working..is i have to set session timeout in IIS
King Fisher 29-Mar-14 3:04am    
to avoid session timeout;
http://snippets.surfthru.com/post/Stop-ASPNET-Session-Timeouts.aspx
LINK 1[^]
LINK 2[^]
LINK 3[^]
LINK 4[^]

LINK 1 is hell of a link thing, will solve your problem.

-KR
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900