6

I'm developing a reminder app in which I'm running a background process and I want to keep it running always so that even if the phone is switched off, the service should remind the user of the reminders that were scheduled for that particular time after the phone is switched on.

Is it possible or do I need to manage it myself?

halfer
  • 19,824
  • 17
  • 99
  • 186
neha
  • 6,327
  • 12
  • 46
  • 78
  • Interesting question, since some Alarms can wake the phone up even when its switched off. I am also interested in the answers – Aman Alam Feb 04 '11 at 10:29
  • 1
    @Sheikh, have you seen any Android device with a working Alarm when the phone is off? Cause I haven't, and these threads agree: [1](http://android.stackexchange.com/questions/4206/does-the-alarm-work-when-my-phone-is-turned-off) and [2](http://android.stackexchange.com/questions/4739/whats-the-reason-that-the-alarm-clock-isnt-working-when-the-phone-is-turned-off) – mdelolmo Feb 04 '11 at 12:11
  • 2
    Wow. I just checked and my piece of Android really doesn't do that. Weird. my old Sony W550i had this awesome feature man. crap! – Aman Alam Feb 04 '11 at 12:33

1 Answers1

0

So you simply want the user to get notified, when he turns his phone ON, that there was a reminder, when your phone was off.

Do one thing: start your app as soon as phone starts. For that you will have to listen to the start up broadcast and start your app.

Then simply compare the present time with the time set in the reminder..
and the notify the user.

You can search the web to find out which broadcast you have to receive and process for starting your application at startup of phone. I think this link might help you.

halfer
  • 19,824
  • 17
  • 99
  • 186
N-JOY
  • 10,344
  • 7
  • 51
  • 69