Android Delayed Notification

后端 未结 1 1132
谎友^
谎友^ 2021-02-19 12:08

I am trying to create a Notification using Android\'s Notification Manager, however, the trick is that I want the notification to show up 30 days in the future. In my code I\'m

相关标签:
1条回答
  • 2021-02-19 12:43

    Is there anyway to make the notification show up in at a future date/time?

    No.

    As Falmarri suggests, you will need to handle this yourself, though I disagree with his approach. You will need to use AlarmManager. However, I am skeptical that AlarmManager will work for 30-day durations, though you can try it. You may need to use AlarmManager for a daily/weekly task to schedule that day's/week's notifications via separate alarms. You will also need to reconstitute this roster of alarms on a reboot, since they get wiped, as Falmarri suggests.

    0 讨论(0)
提交回复
热议问题