By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,986 Members | 2,030 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,986 IT Pros & Developers. It's quick & easy.

Sessions timeout even with activity, what am I doing wrong?

P: 11
ok, so I have a .net form using c#. I'm using a session variable to store some data while entering items in the form since each time you hit the page it initiates a new session which equals a row in a data table.

Now the problem is that the sessions are timing out in 20 minutes (default) even if I am actively using the form. Is there some sort of keep alive function that I am missing?
Apr 25 '07 #1
Share this Question
Share on Google+
2 Replies


TRScheel
Expert 100+
P: 638
ok, so I have a .net form using c#. I'm using a session variable to store some data while entering items in the form since each time you hit the page it initiates a new session which equals a row in a data table.

Now the problem is that the sessions are timing out in 20 minutes (default) even if I am actively using the form. Is there some sort of keep alive function that I am missing?

Interesting... never had that issue.

Why dont you try putting this in your on page load:

Session["YourVariableName"] = Session["YourVariableName"];

For each page... see if just accessing it fixes it.
Apr 25 '07 #2

P: 11
actually i think you are right in that it could be the problem. I was starting a session and then not working with it at all since it is still fairly early development. I just changed some things around and have it so that each page now works with the session variables and hopefully the problem goes away.
May 3 '07 #3

Post your reply

Sign in to post your reply or Sign up for a free account.