How to set multiple alarms using alarm manager in android

You need to use different Broadcast id's for the pending intents. Something like
this:

Intent intent = new Intent(load.this, AlarmReceiver.class);
final int id = (int) System.currentTimeMillis();
PendingIntent appIntent = PendingIntent.getBroadcast(this, id, intent, PendingIntent.FLAG_ONE_SHOT);

Using the system time should be a unique identifier for every pending
intent you fire.

Leave a Comment