1 Reply Latest reply: Aug 21, 2012 10:14 PM by air developer 117 RSS

    iOS,on handle Event.DEACTIVATE, send message to server failed

    air developer 117 Community Member

      I'm trying to capture the "home" button press event, and notify my web server that my iOS application is deactivated, and then, my web server can send messages through APNs.

       

      I tried with this:

      NativeApplication.nativeApplication.addEventListener(Event.DEACTIVATE, this.onDeactivate);

       

      and:

      make a URLRequest in onDeactivate callback function to notify my server.

       

      But i found, this request never got sent. Actually, it is sent when i press "home" again, and after

      my iOS application is activated!

       

      Is there a way to solve or work around?