alarmManager.set(AlarmManager.RTC_WAKEUP, calendar.getTimeInMillis(), sender);
Set the alarm to sound at a specific time as above (multiple)
Is there a way to see the list of alarms?
Thank you^
^ android
Someone wrote how to get a list of getNextAlarmClock()
repeatedly in a foreign country.
Source: https://www.laurivan.com/list-alarms-in-android/
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
private void listAlarms() {
for (AlarmManager.AlarmClockInfo aci = mAlarmManager.getNextAlarmClock();
aci != null;
aci = mAlarmManager.getNextAlarmClock()) {
Log.d(TAG, aci.getShowIntent().toString());
Log.d(TAG, String.format("Trigger time: %d", aci.getTriggerTime()));
}
}
© 2024 OneMinuteCode. All rights reserved.