Jump to content

How to detect phone power down


Guest monikker

Recommended Posts

Guest monikker

I work on an application that needs to do some actions at exit. No problem when user exits it but what if phone is just turned off? I did some tests and it seems that neither WM_CLOSE nor WM_DESTROY are sent when phone is turned off. Is there any way to detect when phone is about to turn off? (Or even better is there a way to detect and delay this for a while?)

Pavel

Link to comment
Share on other sites

Guest Shuflie

I'm not sure if this is possible or not, but could your application intercept the power button before it gets through to the operating system, close gracefully and then send a software power off command?

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.