http://developer.android.com/reference/android/app/ActivityManager.RunningServiceInfo.html

Word of warning though... The Android 2.2 SDK dramatically changed the way
in which you can stop 3rd party applications and your app may not work
properly.  Just something to take into consideration.  It affected my
application and I had to implement some changes to how my app works on
Android 2.2+ and how it runs on previous version.


----------------------------------------------------------------------
There are only 10 types of people in the world...
Those who know binary and those who don't.
----------------------------------------------------------------------


On Mon, Jul 12, 2010 at 1:38 PM, Bret Foreman <bret.fore...@gmail.com>wrote:

> I have an activity that contains a CompoundButton. I want that button
> to reflect the started/destroyed state of a Service. If the button is
> toggled off-to-on, then the service should be created-started. Once
> the service is running, I don't want an exit from the activity to
> destroy it. Alternatively, if the button is toggled on-to-off then I
> want the service destroyed. Upon (re)entry to the activity, the button
> should reflect the correct started/destroyed state of the service.
>
> How can I detect that a service does NOT exist (button unchecked upon
> activity start) without inadvertently creating the service with a
> bindService call?
>
> Thanks
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Beginners" group.
>
> NEW! Try asking and tagging your question on Stack Overflow at
> http://stackoverflow.com/questions/tagged/android
>
> To unsubscribe from this group, send email to
> android-beginners+unsubscr...@googlegroups.com<android-beginners%2bunsubscr...@googlegroups.com>
> For more options, visit this group at
> http://groups.google.com/group/android-beginners?hl=en
>

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en

Reply via email to