3

I am working on Android Marshmallow app, I have runtime permissions set in my app during launch. Once the app is running in background, when user manually disables any one permission (path: Settings > Apps > MyApp > Permissions > Contacts,SMS,Location) my app is getting killed(crashes). Is there a way to handle this situation? I want to know like is there any broadcast receiver to handle my app so that my broadcast receiver will receive that event and again my app will start it?

Thanks !

pmgeek
  • 41
  • 3
  • and if there was ... your app would only start to crash again. I think you should change your app and check/ ask for permissions. – Bö macht Blau Apr 06 '16 at 16:16
  • If your app needs any kind of permission, you should always check if you have that permission granted. If you do, execute your code. If you don't then don't execute it, instead pop up a message specifying that you need that permission turned on in order to continue. – Pztar Apr 06 '16 at 16:32
  • Pztar, Thanks for your valuable feedback. Permissions are all granted fine, permission is disabled in Settings, outside my app and I see that OS is killing my app on manually disabling the permission. Can you help me as to how to handle situations like this, how o pop up a message to the user -'not to disable the app' – pmgeek Apr 06 '16 at 16:46

0 Answers0