Click here to Skip to main content
15,887,988 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
I am using VS 2008 for my application.

Code works fine locally
but on live session expires within 5 - 10 seconds
Please help

What I have tried:

I have tried all the practices to increase the session time out.

Web Config to increase using sessionState
also tried forms timeout
Posted
Updated 9-Oct-16 22:15pm
v2

Presumably, you've checked your existing code and web.config, and tried increasign teh timeout there: HttpSessionState.Timeout Property (System.Web.SessionState)[^]
If that doesn't work, then you need to talk to your web hosting company: I know that some reduce it to five minutes and have set that increases beyond that are ignored, but ten seconds seems rather extreme. If it's been reduced by the web host, then only they can increase it, so if they won't cooperate, you will have to move to cookies.
 
Share this answer
 
Are you using shared hosting provider? If yes, then you cant use session on shared hosting. Most of shared hosting provider don't support session. As an alternative, you can use cookies on your code. Please refer to:

- http://blogs.msdn.com/b/johan/archive/2006/11/20/sessionstate-performance.aspx
- http://forums.asp.net/t/1803857.aspx/1?Session+out+frequently+in+asp+net+
- http://msdn.microsoft.com/en-us/library/ms972429.aspx
 
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