Closing a Webform by clicking the close button
-
Is there an event or function that is fired when the user clicks the close button at the upper right portion of the screen of a WEB PAGE? And if there is, what is it? I am working on this ASP.NET project, and I want to output a message box when that button is clicked. Thank you, The Major Rager
-
Is there an event or function that is fired when the user clicks the close button at the upper right portion of the screen of a WEB PAGE? And if there is, what is it? I am working on this ASP.NET project, and I want to output a message box when that button is clicked. Thank you, The Major Rager
Maybe this should be in the Web Development forum... I think (not sure) the <body> tag has a onClosing event or something:
<html onClosing="DoSomethingWithJavascriptOrSomething">
How you can use this with Asp.Net i have no idea :~ . Pompiedompiedom... ;)
"..Commit yourself to quality from day one..it's better to do nothing at all than to do something badly.." -- Mark McCormick
-
Is there an event or function that is fired when the user clicks the close button at the upper right portion of the screen of a WEB PAGE? And if there is, what is it? I am working on this ASP.NET project, and I want to output a message box when that button is clicked. Thank you, The Major Rager
Hi there, You can hook on OnUnload event of the web form by using js.... << >>
-
Is there an event or function that is fired when the user clicks the close button at the upper right portion of the screen of a WEB PAGE? And if there is, what is it? I am working on this ASP.NET project, and I want to output a message box when that button is clicked. Thank you, The Major Rager
Just as the other two people have said. But, this event can't be handled server-side in ASP.NET. There is no event for it. You can only handle this event in client-sie JavaScript. But, this is really a question for the ASP.NET or Web Development forums. RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome