Free Support Forum - aspose.com

Reminder is not showing in ICS Calendar Using Aspose.Email for JAVA API

Hi,
I have created ICS Calendar using MapiCalendar. I have set Reminder but i did not show Reminder after creating the ICS File. Please provide me the exact solution of this issue.
I am waiting for your response.
Test Reminder 2 weeks.ics.zip (583 Bytes)

@kharade.a,

You may please give a try to the following sample code and share the feedback.

Date startDate = new Date();
Date endDate = new Date();
endDate.setTime(startDate.getTime() + 10000);
MailAddressCollection attendees = new MailAddressCollection();
attendees.addItem(new MailAddress("attendee_address@domain.com", "Attendee"));

Appointment app = new Appointment("Home", startDate, endDate, new MailAddress("organizer@domain.com", "Organizer"), attendees);

MailMessage msg = new MailMessage();
msg.addAlternateView(app.requestApointment());
MapiMessage mapi = MapiMessage.fromMailMessage(msg);
MapiCalendar cal = (MapiCalendar) mapi.toMapiMessageItem();

cal.setReminderSet(true);
cal.setReminderDelta(45); //45 min before start of event

String savedFile = "calendarWithDisplayReminder_out.ics";
cal.save(savedFile, AppointmentSaveFormat.Ics);

I have used same code but still it is not showing.

@kharade.a,

We have observed the issue and logged under Id:EMAILJAVA-34357 for further investigation. We will write back here once issue is analyzed and feedback is ready to share.