AuxOne wrote:
>> On the whole, that's not a good idea. Popping up an Activity in the
>> middle of whatever the user is doing will not be popular. There are
>> certain circumstances where this is appropriate -- incoming VOIP calls,
>> etc. -- but should not be done in general. Users will attack you with
>> sharp pointy things.
> 
> The reason I need the Activity is because I'm making some queries to
> the Contact database and I need to the ContentResolver.

Call getContentResolver() in your Service.

> Can't it launch "minimized"?

There is no such concept in Android.

> Do you mean the AppService class? I'm trying to do "startActivity()"
> from the doWakefulWork but there doesn't appear to be a Context.

The Service is a Context.

> Your example code has the Alarm scheduled from the BootReceiver, how
> do I make the Activity schedule it? 

Put the alarm-scheduling code in a static method somewhere, and call it
from both places.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://twitter.com/commonsguy

Android Online Training: 26-30 April 2010: http://onlc.com

-- 
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

To unsubscribe from this group, send email to 
android-developers+unsubscribegooglegroups.com or reply to this email with the 
words "REMOVE ME" as the subject.

Reply via email to