GPS service module and displaying speed

bluedude

Well-Known Member
Licensed User
Longtime User
Erel,

You say it is best to store stuff from the service in a global variable or even mapping.

However, I have two situations. One is that only the services runs and stores GEO and speed and second is that my main activity is active and I want to display speed realtime on the screen.

What would be best? To use a global variable in the service that tells me if the main activity is active? If yes it also needs to update the speed label in the layout.

How can I check if an activity is active from the service?
 
Top