I have create an app, and I set a datetime value, when hits the datetime value, the app will trigger the function on Android phone background. Any idea?
Asked
Active
Viewed 4,557 times
3 Answers
3
You need to setup the Alarm and Receiver for it. http://developer.android.com/reference/android/app/AlarmManager.html
For example: http://www.techrepublic.com/blog/android-app-builder/use-androids-alarmmanager-to-schedule-an-event/

goodm
- 7,275
- 6
- 31
- 55
1
Good answers from @jcage and @goodm.
Just a hint: Don't forget to reset Alarm at device boot via a ACTION_BOOT_COMPLETED
receiver in manifest. http://developer.android.com/reference/android/content/Intent.html#ACTION_BOOT_COMPLETED

Kevin Yuan
- 1,008
- 8
- 20