Ask a Question related to ASP.NET General, Design and Development.
-
Marcelo #1
Re: Session time-out
Thanks George, Kevin. I think I need to clarify. I wasn't
expecting the browser to be smart enough to know when a
session did terminate, neither trying to implement a
timer of any kind.
I completely understand (and I have tested it) that the
only way for the web server to know that a session has
timed-out is by placing a request to the server.
I assumed that this was understood in my e-mail. I am
going to clarify all this by saying that after the
session timed-out and after a request has been placed,
the redirection code that I put in the Global.asax.vb
file did not working.
I have already found a work around. So in the mean time I
will use what I came up with.
If any of you know of the "right" way of doing this,
please let me know.
Thank you both.
notification when user id>-----Original Message-----
>You must understand that Server has does not getrequest.>taking a coffee brake nor closed the browser.
>
>
>So Session times out 20(configurable) minutes after lasthappens when there is no>The key here "Last Request" meaning that time outredirected>request.
>So there is no one to redirect.
>
>George.
>
>"Marcelo" <mareal@remember.com> wrote in message
>news:694d01c3583f$fd62a430$a001280a@phx.gbl...>> What's secret for the user to be automatically>>> to the login page when a session has timed-out?
>>
>> I have tried adding the following line:
>>
>> System.Web.HttpContext.Current.Response.Redirect
>> ("login.aspx")
>>
>> in the Global.asax.vb file under the following method
>>
>> Sub Session_End(ByVal sender As Object, ByVal e As
>> EventArgs)
>>
>> But it does not work.
>>
>> Thanks in advance.
>
>.
>Marcelo Guest
-
how i can set session time out peiod
hi all, How i can set the session time out period of asp.net session.Since i am anovice programmer it will be very helpful if u give details... -
Session time outs
I have a user authentication system in my application that allows you to log in and view certain areas of the site based on a session variable. I?m... -
Session Time Out
Hello i'am using dreamveaver mx 2004 i want to know how i can control Session Ex: i want it to be for 30 minutes and then expire??? -
Session one more time
Hi, I have a login page (without frames). After the user login s/he lands on the site with 2 frames. Their names are top and bottom. I post the... -
session time
To: All I have some question how can do it when the session timeout after that will propmt the message and redirect to login page for login... -
Lewis Wang [MSFT] #2
RE: Session time-out
Thanks George, Kevin for the replies.
Hi Marcelo,
You can use Response.AddHeader("Refresh",Convert.ToString
((Session.Timeout+ 1))) in Page_Load to cause the page refresh when the
session is timeout. You also can use
"Response.AddHeader("Refresh",Convert.ToString ((Session.Timeout+
1))+";URL=login.aspx")" to redirect the page to login page.
Check this link, I think it is helpful.
[url]http://www.4guysfromrolla.com/webtech/tips/t022800-1.shtml[/url]
Please let me know if you need more information.
Best Regards,
Lewis
Get Secure! - [url]www.microsoft.com/security[/url]
This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------
| Content-Class: urn:content-classes:message
| From: "Marcelo" <mareal@remember.com>
| Sender: "Marcelo" <mareal@remember.com>
| Subject: Session time-out
| Date: Fri, 1 Aug 2003 08:17:15 -0700
| Lines: 16
| Message-ID: <694d01c3583f$fd62a430$a001280a@phx.gbl>
| MIME-Version: 1.0
| Content-Type: text/plain;
| charset="iso-8859-1"
| Content-Transfer-Encoding: 7bit
| X-Newsreader: Microsoft CDO for Windows 2000
| X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
| Thread-Index: AcNYP/1ixP3l7y5oSCGj2MVbJiRZKw==
| Newsgroups: microsoft.public.dotnet.framework.aspnet
| Path: cpmsftngxa06.phx.gbl
| Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.framework.aspnet:164149
| NNTP-Posting-Host: TK2MSFTNGXA08 10.40.1.160
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
|
| What's secret for the user to be automatically redirected
| to the login page when a session has timed-out?
|
| I have tried adding the following line:
|
| System.Web.HttpContext.Current.Response.Redirect
| ("login.aspx")
|
| in the Global.asax.vb file under the following method
|
| Sub Session_End(ByVal sender As Object, ByVal e As
| EventArgs)
|
| But it does not work.
|
| Thanks in advance.
|
Lewis Wang [MSFT] Guest
-
Hans Kesting #3
Re: Session time-out
"Lewis Wang [MSFT]" <v-lwang@online.microsoft.com> wrote in message
news:vZfUZayWDHA.2192@cpmsftngxa06.phx.gbl...Watch out: Session.Timeout is in minutes and Refresh works in seconds!> Thanks George, Kevin for the replies.
>
> Hi Marcelo,
>
> You can use Response.AddHeader("Refresh",Convert.ToString
> ((Session.Timeout+ 1))) in Page_Load to cause the page refresh when the
> session is timeout. You also can use
> "Response.AddHeader("Refresh",Convert.ToString ((Session.Timeout+
> 1))+";URL=login.aspx")" to redirect the page to login page.
>
You need to work a " * 60 " in there.
Hans Kesting
rights.> Check this link, I think it is helpful.
>
> [url]http://www.4guysfromrolla.com/webtech/tips/t022800-1.shtml[/url]
>
> Please let me know if you need more information.
>
> Best Regards,
> Lewis
>
> Get Secure! - [url]www.microsoft.com/security[/url]
> This posting is provided "AS IS" with no warranties, and confers nomicrosoft.public.dotnet.framework.aspnet:164149>
> --------------------
> | Content-Class: urn:content-classes:message
> | From: "Marcelo" <mareal@remember.com>
> | Sender: "Marcelo" <mareal@remember.com>
> | Subject: Session time-out
> | Date: Fri, 1 Aug 2003 08:17:15 -0700
> | Lines: 16
> | Message-ID: <694d01c3583f$fd62a430$a001280a@phx.gbl>
> | MIME-Version: 1.0
> | Content-Type: text/plain;
> | charset="iso-8859-1"
> | Content-Transfer-Encoding: 7bit
> | X-Newsreader: Microsoft CDO for Windows 2000
> | X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
> | Thread-Index: AcNYP/1ixP3l7y5oSCGj2MVbJiRZKw==
> | Newsgroups: microsoft.public.dotnet.framework.aspnet
> | Path: cpmsftngxa06.phx.gbl
> | Xref: cpmsftngxa06.phx.gbl> | NNTP-Posting-Host: TK2MSFTNGXA08 10.40.1.160
> | X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
> |
> | What's secret for the user to be automatically redirected
> | to the login page when a session has timed-out?
> |
> | I have tried adding the following line:
> |
> | System.Web.HttpContext.Current.Response.Redirect
> | ("login.aspx")
> |
> | in the Global.asax.vb file under the following method
> |
> | Sub Session_End(ByVal sender As Object, ByVal e As
> | EventArgs)
> |
> | But it does not work.
> |
> | Thanks in advance.
> |
>
Hans Kesting Guest



Reply With Quote

