Detecting whether an app is running in the background and NOT running in the foreground?

HippoMan

New member
Under certain conditions, I want to test whether a particular app is running in the background, but NOT running in the foreground.

Is this possible?

Thank you very much in advance.
 

Endercraft

Moderator (& bug finder :D)
Under certain conditions, I want to test whether a particular app is running in the background, but NOT running in the foreground.

Is this possible?

Thank you very much in advance.
If it runs in background that means it's not in the foreground and vice-versa...
 

Endercraft

Moderator (& bug finder :D)
You have the application running constraint but apparently 'in background' and 'not running' options don't work on Android 8+ and I didn't know that...
 

FrameXX

Well-known member
If it runs in background that means it's not in the foreground and vice-versa...

I think what @HippoMan rather meant was the app being actively running in the background and doing something, but at the same time not being in foreground.

There's no other way than a rooted device to be able to check if app is running in background on Android 8+. Only way I can think of you could recognize it, would be if the app shows a permanent notification if running, like MacroDroid is doing. Than you could use the notification present constraint.
 
Top