Is there a way in Android to get the upcoming alarm time?
Thanks
Clarification: I am talking about the native android Alarm Clock appliction
String nextAlarm = Settings.System.getString(getContentResolver(),
Settings.System.NEXT_ALARM_FORMATTED);
Starting with API level 21 the constant Settings.System.NEXT_ALARM_FORMATTED
is deprecated.
Instead, you should use:
AlarmManager.getNextAlarmClock()
https://developer.android.com/reference/android/app/AlarmManager.html#getNextAlarmClock()
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With