Author: eappell | Posted on: 7/23/2008 12:23:05 PM | Views : 353

I need to have a way of querying the server and getting the user's time left before the session expires.  That's it.  I put this code into the OnTick event of my Ajax Timer control and do stuff based on the value of the time left.  But it seems to be impossible to do without actually refreshing the session on the server.  I've been working on this for 3 DAYS now, and I have to admit, I'm ready to jump out the window.  Everything I try fails at some point...  It shouldn't be this hard!!!

So I first tried the method outlined in many articles that recommends using Session.Timeout.  Every time it comes back it's the same exact number of minutes.  So it seems that it's just refreshing the session on the server, which is definitely NOT what I want to do.

So then I tried using the FormsAuthenticationTicket Expiration value, but it turns out that if you have sliding expiration enabled in web.config ...

Go to the complete details ...