Service without a UI
-
I've got a few apps that I wrote years ago that do their work in the background, mostly listening for certain events to happen. I used a
Service
for this. If the phone was rebooted for whatever reason, theService
gets restarted when aACTION_BOOT_COMPLETED
broadcast is received. This all worked quite well for my needs. When I upgraded my phone to Android 10 a few months ago, those apps stopped working (Android's new security features). I found and implemented the recommended solution (by supplying an ongoing notification while the service is running), but it still does not behave in the way I desire. Other apps, like Outlook, ADT Pulse, and myQ, also listen in the background but they do not require a notification to be shown. You don't see anything until an email is received, the alarm is set, or the garage door is opened, respectively. Then when you click on the notification, the app opens for you to interact with. So my question is, how do these apps run with no initial UI, yet still do their work in the background? Thanks. DC"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"You can easily judge the character of a man by how he treats those who can do nothing for him." - James D. Miles