hello, is there a methods to keep mobile phone off using code, i have no idea about this,and hope someone give me some advice,or example , code,api
thank you
hello, is there a methods to keep mobile phone off using code, i have no idea about this,and hope someone give me some advice,or example , code,api
thank you
You can detect shutdown is occurring by using an Intent Receiver for the ACTION_SHUTDOWN intent. This is intended to make sure applications save any required information to disk that is specific to shutting down to prevent loss of user information.
See how to use the ACTION_SHUTDOWN intent here.
As for stopping shutdown, I'm pretty sure it's not possible on Android.