how to know user has closed application directly.

Posted by Abhi_patil under ASP.NET on 4/7/2009 | Views : 1157 | Status : [Member] | Replies : 1
i want to perform some code when user closes application directly.

i want to tranfer control to logout page when user closes application directly.


Posted by: Vuyiswamb on: 4/7/2009 [Member] [MVP] [Administrator] NotApplicable

Good Day Abhi_patil

I assume you mean when a user click the (X) button to close the page. This can be done in Javascript like this

<BODY onUnload="alert('Are you sure

you have spent long enough on this lovely page?')">

or Check this

Thank you for Posting in DotnetFunda

Were are looking forward for your reply

Vuyiswa Maseko

Thank you for posting at Dotnetfunda

Abhi_patil, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response