Android Permission Denial: forceStopPackage()

前端 未结 2 806
一整个雨季
一整个雨季 2021-01-16 11:57

I am try to kill another application using forceStopPackage(). But my application shows runtime error.

Error :

jav         


        
2条回答
  •  天涯浪人
    2021-01-16 12:50

    You have to add the permission in the AndroidManifest.xml like below.

    
    

    Make sure only if your app is signed with system key os will allow to stop other apps.

提交回复
热议问题