PC Review


Reply
Thread Tools Rate Thread

Detect when the session is going to time out and display some kind of message.

 
 
UJ
Guest
Posts: n/a
 
      11th Aug 2005
How do you detect when your session is going to timeout and display a
message saying 'unless you do something you will be logged out' much the way
bank web pages do?

Can you do it for the site or do you need to put code on every page doing
it?

TIA


 
Reply With Quote
 
 
 
 
Curt_C [MVP]
Guest
Posts: n/a
 
      11th Aug 2005
UJ wrote:
> How do you detect when your session is going to timeout and display a
> message saying 'unless you do something you will be logged out' much the way
> bank web pages do?
>
> Can you do it for the site or do you need to put code on every page doing
> it?
>
> TIA
>
>


Nope...you could toss a timer on the page and do it yourself, but you
can't poll the session timer, without restarting it...


--
Curt Christianson
site: http://www.darkfalz.com
blog: http://blog.darkfalz.com
 
Reply With Quote
 
Lucas Tam
Guest
Posts: n/a
 
      11th Aug 2005
"UJ" <(E-Mail Removed)> wrote in
news:eVDZ#(E-Mail Removed):

> How do you detect when your session is going to timeout and display a
> message saying 'unless you do something you will be logged out' much
> the way bank web pages do?
>


You could put a javascript timer on the page to detect idleness.

Or if you're using SQL server as your state server, you could poll a web
service using client javascript to get a more accurate time. Just make sure
the web service is running under a different app than your ASP.NET
application, otherwise the session timer will get reset on each request.



--
Lucas Tam ((E-Mail Removed))
Please delete "REMOVE" from the e-mail address when replying.
http://members.ebay.com/aboutme/coolspot18/
 
Reply With Quote
 
UJ
Guest
Posts: n/a
 
      12th Aug 2005
Thanks Lucas. That's what I ended up having to do.

"Lucas Tam" <(E-Mail Removed)> wrote in message
news:Xns96AF783A6FFC0nntprogerscom@127.0.0.1...
> "UJ" <(E-Mail Removed)> wrote in
> news:eVDZ#(E-Mail Removed):
>
>> How do you detect when your session is going to timeout and display a
>> message saying 'unless you do something you will be logged out' much
>> the way bank web pages do?
>>

>
> You could put a javascript timer on the page to detect idleness.
>
> Or if you're using SQL server as your state server, you could poll a web
> service using client javascript to get a more accurate time. Just make
> sure
> the web service is running under a different app than your ASP.NET
> application, otherwise the session timer will get reset on each request.
>
>
>
> --
> Lucas Tam ((E-Mail Removed))
> Please delete "REMOVE" from the e-mail address when replying.
> http://members.ebay.com/aboutme/coolspot18/



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
What kind of search path is used in design time and run time when using class library. tony Microsoft C# .NET 0 3rd Apr 2006 08:25 AM
What kind of search path is used in design time and run time when using class library. tony Microsoft Dot NET 0 3rd Apr 2006 08:21 AM
Detect any kind of activity in a window. UJ Microsoft Dot NET Framework Forms 2 7th Dec 2005 06:19 PM
display the time a message is sent Eleni Windows XP Messenger 2 5th Sep 2004 01:15 AM
How to display who sent email message and time mkwdrs Microsoft Outlook VBA Programming 1 8th Nov 2003 02:38 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 01:39 AM.