On Mon, May 16, 2011 at 3:22 AM, Mark Cz <[email protected]> wrote: > Thanks Mark, > I haven't clarify myself in the previous form. > I have two (or more) apks/applications, When the user opens one of my > applications (called APP A), it starts a service, > when the user opens another application (called APP B), it doesn't > start a service but uses the service. But i want to get this behavior > when the > user chooses to open first APP B and then APP A.
startService() starts the service if it is not running. bindService() with FLAG_AUTO_CREATE will start the service if it is not running. Whether these are called from App A, App B, App C, App D, etc. makes no difference. App A will always be the one "running" the service, insofar as it will run in App A's process. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy Android Training in London: http://bit.ly/smand1, http://bit.ly/smand2 -- 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

