Hi
User should be automatically logout if he/she closes the session without proper steps like closing the browsing without logging out or shut downing the system without logging out or system shutdowns because of power issues.
Loading
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend4days leftRegister
Sukesh MarlaRank #461 · 5.4K reputationPosted Aug 21, 2012, 8:54 AM EDT
Session values get cleare autoatically when browser closes or system shutdowns
Hope this helped, check this is correct answer if it is.
Akkiraju IvaturiRank #473 · 5.3K reputationPosted Aug 21, 2012, 6:40 PM EDT
Jignesh TrivediRank #16 · 50.3K reputationPosted Aug 21, 2012, 7:36 PM EDT
I think the only good way to do this is by setting a timeout on the session variables on the server. A web server has no way to know for sure whether a user has closed his browser or not.Javascript is not a good option, since you can disable it client-side.
but you can detect browser closing event when user click on [X] button.
please refer
http://weblogs.asp.net/kodali/archive/2010/04/29/asp-net-session-on-browser-close.aspx
http://www.codeproject.com/Articles/10771/Detect-browser-closing-through-clicks-on-the-X-but
hope this will help you.