We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Setting MapiTask recurrence throwing an exception


Please I would like some help about setting recurrence in a MapiTask.
I’m using the following code bellow:

(1) MapiCalendarWeeklyRecurrencePattern pattern = new MapiCalendarWeeklyRecurrencePattern();
(2) pattern.setPatternType(MapiCalendarRecurrencePatternType.Week);
(3) pattern.setWeekStartDay(MapiCalendarDayOfWeek.Sunday);
(4) pattern.setPeriod(1);
(5) pattern.setDayOfWeek(MapiCalendarDayOfWeek.Monday | MapiCalendarDayOfWeek.Friday);
(6) pattern.setEndType(MapiCalendarRecurrenceEndType.NeverEnd);		
(7) task.setRecurrence(pattern);

The line (5) is throwing the following exception:
Specified argument was out of the range of valid values.
Parameter name: value

Can you give me some advice on how to solve this issue?
I’m using Aspose.Email for Java 20.9



I have created an issue with ID EMAILJAVA-34755 in our issue tracking system to further investigate and resolve the issue. This thread has been linked with the issue so that you may be notified once the issue will be fixed.