Snake
Snake

Reputation: 14648

How to do reminder (alarm) for certain date/time)

I am making an application that you create events and reminder has part of them. I am ok with the event creation but I am not sure about to go with reminder.What do you use for it? If the application is closed can I still have it running in the background (kind of like the android calendar)

Thank you very much

Upvotes: 0

Views: 917

Answers (1)

user468311
user468311

Reputation:

You can use AlarmManager to schedule events. But when device is turned-off, all alarms are canceled, so you should have a BroadcastReceiver which will listen to BOOT_COMPLETED intent and re-schedule events(which should be stored somewhere: shared preferences or sqlite).

Upvotes: 1

Related Questions