Android Question Start Service After Install?

Computersmith64

Well-Known Member
Licensed User
Longtime User
I have created a start at boot, sticky service with no UI:

B4X:
#StartAtBoot: True
#StartCommandReturnValue: Android.app.Service.START_STICKY

&

AddReplacement(android.intent.action.MAIN, unused_action)

This all works really well, except that the service doesn't start after it's installed. To get it to start, I need to reboot the device. Is there a way to get the service to start immediately after it has been installed & without a reboot?

Thanks - Colin.
 

Computersmith64

Well-Known Member
Licensed User
Longtime User
Thanks Erel. I guess this would work for updates, but according to further research I've done a newly installed app can't be started without an explicit action from the user, or in the case of a "start at boot" service or app, when the device is restarted.
 
Upvote 0
Top