Did you check this thread in depth: https://forums.adobe.com/thread/490031?start=0&tstart=0 ?
It may contain useful info for you. Also, note that using this event doesn't mean that your application won't be able to be closed, that could be a disaster, there are ways of forcing your app to be closed, and Windows may do it under some situations. On Wed, Jan 20, 2016 at 9:40 AM, Nicolas Flandrin <nfland...@cylande.com> wrote: > > Hey Osman, > > We do this like this : > > stage.nativeWindow.addEventListener(Event.CLOSING, onClosing); > > private function onClosing(pEvent:Event):void > { > pEvent.preventDefault(); > //doYourClosingJob > //call this to finally close the app > stage.nativeWindow.close(); > } > > -----Message d'origine----- > De : osman [mailto:osman.ul...@gmail.com] > Envoyé : mardi 19 janvier 2016 22:27 > À : users@flex.apache.org > Objet : NativeApplication exiting event in Windows > > Hey everyone, > > I am trying to prevent Windows from shutting down my app on logout so that > I can run some cleanup routines. However it looks like no matter what I do, > Windows kills my app. According to all the documentation I have seen > online, I am supposed to listen for the NativeApplication.EXITING event and > call > preventDefault() on the event. Calling preventDefault() works when I am > testing by just closing the app. However when I log out the app just exits > and event.preventDefault() doesn't seem to work. > > Is this just not possible anymore? I am currently using version 4.12 of > the SDK. > > Thanks > > > > -- > View this message in context: > http://apache-flex-users.2333346.n4.nabble.com/NativeApplication-exiting-event-in-Windows-tp11792.html > Sent from the Apache Flex Users mailing list archive at Nabble.com. >