I have the following in my web application to perform some shutdown database stuff when the user closes the browser window:
window.onunload = cleanExit;
However, this doesn't seem to work in my application inside of Adobe AIR. Is there a way to detect that the window is closeing (in html/ajax)?
is that html-based or Flash platform based application? Also I'm not exactly sure about "user closing window":
- if you have html based application then you could add closing listener via:
and implement similar solution.
I have no idea how Adobe WebKit version handles "unload"/"beforeunload" events - so it could be better to go routine via containing component I think.
I'll give this a try tommorrow.