This is a discussion on Problem in Session TimeOut within the ASP and ASP.NET Programming forums, part of the Web Development category; Hi there, I'm trying to maintain a session for 10 hours. Below tags are in my web.config file. ...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
| |||
| Hi there, I'm trying to maintain a session for 10 hours. Below tags are in my web.config file. Code: <sessionState mode="InProc" cookieless="false" timeout="600" /> <forms loginUrl="login.aspx" timeout="600"></forms> I'm not getting redirected to the login page but I loose my session data. I don't know where I'm doing wrong....
__________________ S.VinothkumaR Behind me is infinite power, Before me is Endless Possibility, Around me is Boundless Opportunity, Why should I fear! |
| Sponsored Links |
| |||
| Hi Vinoth, You have to modified the session timeout in IIS. Just do as following. Right click on the virtual folder, select properties, click Configuration, and go to the Options tab, and the that timeout to 600 as well. That's it..
__________________ Krishnakumar.S Beware of Everything -that is un true; stick to the Truth shall succeed slowly but steadily |
| |||
| Ya buddy, It's working...thanx a lot ... ![]()
__________________ S.VinothkumaR Behind me is infinite power, Before me is Endless Possibility, Around me is Boundless Opportunity, Why should I fear! |
| |||
| Strange, because the session setting in IIS options tab has nothing to do with asp.net session state. It is for ASP session state only. I will guess you lost your session because you're using InProc mode and the app got restarted. |
| |||
| Well, I would have presumed that it did not matter, but it does. What happens is that if the IIS timeout is shorter than the session timeout in the Web.Config file, you get to a page where the session is no longer valid, though the ASP.NET session does not actually timeout (the user is not redirected to the Login page).
__________________ Krishnakumar.S Beware of Everything -that is un true; stick to the Truth shall succeed slowly but steadily |
| |||
| session.setMaxInactiveInterval(60) ; In this case, the session times out after 1 min. session.setMaxInactiveInterval(39600) ; which indicates that the session would be timed out after 11 hours of inactivity. But, this never happens and even after 11 hours of inactivity I can still use the application. I have tried setting this to 3600 sec (1 hr)... but it doesnt work here too. Can somebody tell me why is it so? |
| |||
| Hi all, Session is not getting expired. I am setting a value for session.timeout in codebehind in one of my file but its not getting expired.. Any one plz help me...... I am overwriting the timeout in web.config with the time i want as per my requirement...Actually i am getting that value from database and assigning to session.timeout..and i am keeping idle for that much time eventhough its not getting expired... In one of my file i am taking as Code: Session["TimeOut"] = SessionExpiry; //Some value which i am getting from database Session.Timeout = SessionExpiry; And in Master-Header page i am checking for Code: if (Session["TimeOut"] == null)
{
Response.Redirect("Default.aspx");
} |
![]() |
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| copy information from $_SESSION when timeout.? | saravanan | PHP Programming | 0 | 03-19-2008 09:24 PM |
| copy information from HttpSession when timeout.? | saravanan | Java Server Pages (JSP) | 0 | 03-19-2008 09:22 PM |
| Destroy session using session ID | Jeyaseelansarc | PHP Programming | 1 | 09-07-2007 07:42 AM |
| How to check if a session is about to timeout | KiruthikaSambandam | ASP and ASP.NET Programming | 1 | 08-08-2007 04:25 AM |
| Session Problem | raj | PHP Programming | 1 | 07-17-2007 03:54 AM |