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

Free Support Forum - aspose.com

Issue with First/Last work day of iCalendar pattern (SETPOS)

We encountered an issue with occurrence generation of iCalendar patterns using SETPOS=-1


Test 1:
RecurrencePattern(“DTSTART:20160118T100000\r\nRRULE:FREQ = MONTHLY; BYDAY = MO,TU,WE,TH,FR; BYHOUR = 12; BYMINUTE = 0; BYSETPOS = -1”);
var dates = pattern.GenerateOccurrences(new DateTime(2016, 1, 19, 9, 0, 0), new DateTime(2016, 2, 19, 9, 0, 0));
Assert(dates.Count == 1); // Fails - 2 dates are generated. One at the correct instance of 1/29/16 @ 12 PM but also one at 1/19/16 @ 12 PM

Test 2:
RecurrencePattern(“DTSTART:20150119T100000\r\nRRULE:FREQ = MONTHLY; BYDAY = MO,TU,WE,TH,FR; BYSETPOS = -1”);
var dates = pattern.GenerateOccurrences(new DateTime(2016, 1, 19, 9, 0, 0), new DateTime(2016, 2, 19, 9, 0, 0));
Assert(dates.Count == 1); // Fails - 2 dates are generated. One at the correct instance of 1/29/16 @ 12 PM but also one at 1/19/16 @ 9 AM

Testing with SETPOS=1 also fails in the same way.

Note that “DTSTART:20160119T100000\r\nRRULE:FREQ = MONTHLY; BYDAY = MO,TU,WE,TH,FR; BYHOUR = 5; BYMINUTE = 0; BYSETPOS = -1” works. It seems that if the time component of DTSTART is after the time component of the pattern.

This was tested with 6.0 and 6.1 versions of Aspose.Email

Hi Tim,

Thank you for contacting Aspose Support team.

We have investigated this issue at our end and logged it as EMAILNET-35103 in our issue tracking system for further investigation by our Product team. This ticket has been linked with the logged ticket so that once there is some update available about the fix, you’ll be notified automatically via this thread.

Just curious if there is an ETA on the fix for this. If it will take awhile, we will implement a workaround.


Thanks.

Hi Tim,


The issue has been fixed and will be part of our upcoming release of .NET API. It will be available by the end of next week. We shall update you here once the fix version is available for download.

The issues you have found earlier (filed as EMAILNET-35103) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by Aspose Notifier.

The update fixed our issues. Thank you for the quick reply.

Hi Tim,


Thank you for the feedback.