Is there a method or event that response to the user clicking on the 'X' of the browser?
I know that Session_End gets called, but it doesn't get called immediately after the user clicks on the 'X'. It'll only fires when the session has expired.
Nope, because when the user clicks the browser windows the page is not resent to the server, so the server does not get told when the user clicks the x, so there is nothing you can do. You can use a javascript on page close to do something client side, but you will not be able to communicate with the server though this.
But since I just found a solution, I might as well share it with everyone else.
I would create the onUnload event handler, which calls a function (javascript) to open a window which runs your server-side stuffs. Then closes the new window.
Originally posted by PeOfEo eh, darn you running 200mhz faster then me at the moment, Let me bust out the motherboard monitor and change that. You build your system yourself?
Sorry. Actually, it's a work puter. I don't really put a whole system together, but once it's together I can troubleshoot on my own.
mainly vb.net, I am more comfortable with the syntax, but if I were required to code in c# for a job or something I could probably make do (it might require a bit of learning for more advanced stuff since I never use c#).
Bookmarks