On Wed, Aug 11, 2010 at 6:26 AM, Bob Kerns <r...@acm.org> wrote:

> But you want the service context, which is just 'this' (i.e. the
> service itself). The application context would work too, but generally
> you should go with the most specific context available unless you have
> a reason otherwise. Using some context (in this case, some activity's
> context) that you're not running in doesn't really make any sense.
>

QFE

Side-note: stay away from getApplicationContext() - it does nothing remotely
useful other than cause bugs and confusion.

-------------------------------------------------------------------------------------------------
TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago
transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to