-3

I would like to store the package name when user launch the application.When user open a application i would like to get that package name.

Thanks in advance.

Narender Reddy
  • 463
  • 6
  • 18

1 Answers1

0

It is possible if API version < 21, but not newer version. Look at GET_TASKS permission:

https://developer.android.com/reference/android/Manifest.permission.html#GET_TASKS

This can be easily abused so it is good to deprecate it.

Aimin Pan
  • 56
  • 1