I have 2 applications. The first is a standard activity with a "start
service" button. The second is a service only application. It has no
activity. It does have a receiver which listens for the BOOT_COMPLETED
intent.
After I've installed both applications on my handset I run the first
app. When I press the "start service" button on the first app, I'd
like to send an intent to the second app to starts its service.
If the service was part of app1, I could create an intent like this...
startService(new Intent(this, MyService.class));... and the service
would start. But MyService is part of another application so I cant
use MyService.class, in app1.
I've tried creating an intent like this in app1
Intent i = new Intent();
i.setClassName("com.backgroundService", "MyService ");
startService(i);
but the service doesnt start.
What information do I need to put in the intent to start a remote
service?
Do I need a receiver associated with the service to handle the intent
and start the service? If so, what ACTION and CATEGORY do I use in
the services manifest for the receiver?
Thanks for your help
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en