?
Solved

Session Time out on apsx page

Posted on 2009-05-08
3
Medium Priority
?
361 Views
Last Modified: 2012-06-21
Hi all,

I have included this
HttpContext.Current.Response.AppendHeader("Refresh", Convert.ToString(((HttpContext.Current.Session.Timeout * 60) - 10)) & "; Url=Login.aspx?Yoursession=expired")

on all pages, accordingy to one of the post for the redirection
and  this below in web.config file
<sessionState mode="InProc" cookieless="false" timeout="60"/>
Please let me know,
1) What the  http context statement means?(especially this  60) - 10)) )
2) Is it the correct way of including the session timeout and redirection?
3) even if i have given 60 mins and i'm using the page, the session expires.
4) I the above (4) is happening, where else can i look , what could be wrong?
can you please direct me to use the correct way of the page expiration.
Thanks
0
Comment
Question by:SaraDob
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 1

Author Comment

by:SaraDob
ID: 24338791
anyone?
0
 
LVL 20

Accepted Solution

by:
informaniac earned 750 total points
ID: 24403205
Have u stored any kind Session variable like Session["UserID"]

If yes you could just do this

if(HttpContext.Current.Session["UserID"] == null)
{
           Response.Redirect("SessionExpired.aspx");
}
0
 
LVL 1

Author Closing Comment

by:SaraDob
ID: 31579552
Thanks for the solution
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this Article, I will provide a few tips in problem and solution manner. Opening an ASPX page in Visual studio 2003 is very slow. To make it fast, please do follow below steps:   Open the Solution/Project. Right click the ASPX file to b…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
In this video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…
Michael from AdRem Software outlines event notifications and Automatic Corrective Actions in network monitoring. Automatic Corrective Actions are scripts, which can automatically run upon discovery of a certain undesirable condition in your network.…
Suggested Courses

765 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question