1

Check if Activity is running from Service of Same Package

view story
linux-howto

http://stackoverflow.com – THis is more of a doubt. Currently, my code works fine, but I want to make sure I'm doing it the right way. I have a service, which checks if and Activity is running on the foreground. If it is, it sends a Broadcast to the activity, so the activity updates some stuff on the screen. I created an Intent Filter on the service: com.harkdev.ServerStatus.SERVER_UPDATED Here the Service need to know if the activity is on the foreground, so it uses the IsActivityRunning method, which reads the running tasks from the ApplicationManager. This means that I need to set the GET_TASK permission. Being t (HowTos)