First of all, create a new ASP.NET page in your favorite IDE and add an instance of the ScriptManager to it. Make sure you configure the ScriptManager to enable Page Methods. Next, we will subscribe to the unload event of the body tag of the ASP.NET page and assign a callback method to be called when this event fires.
I wanted to know when the browser is closed at server side in asp.net 2.0. How to detect in code behind?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With