Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 
  • kill android application all activities process

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 294
    Comment on it

    We know that on back press of button in any android application can finish the app or an activity but some process of application still works in background so if you want to kill all the processes of any application you can kill app process like this :

      @Override
    public void onBackPressed() {    
        android.os.Process.killProcess(android.os.Process.myPid());
    }
    

    Here method killProcess kill the process with the given package id. so this method allows us to request to kill any process based on its package id but the kernel will still impose some restrictions on some pid.

 0 Comment(s)

Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: