4

I want to close all running app in android and also i want get the quantity of memory which were free by close all running app.

how to do that.

Hiren Patel
  • 52,124
  • 21
  • 173
  • 151

1 Answers1

6

You can only kill your own apps, e.g. the ones running in the same process or with the same userID. You can not kill others, unless the device is rooted.

Have a look at this answer though, about 'killing' background processes of apps.

Community
  • 1
  • 1
Jeffrey Klardie
  • 3,020
  • 1
  • 18
  • 23
  • thanks a lot for answer but my question is that the android app https://play.google.com/store/apps/details?id=com.cleanmaster.mguard&hl=en, this app close all running app anagrammatically, i want to learn that. thanks. – Hiren Patel Nov 01 '13 at 13:12
  • Such apps only kill background processes of apps. Have a look at the documentation of killBackgroundProcesses(): http://developer.android.com/reference/android/app/ActivityManager.html#killBackgroundProcesses(java.lang.String). This is available from API level 8 and up. – Jeffrey Klardie Nov 01 '13 at 13:13