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

Free Support Forum - aspose.com

Problem generating dates using GenerateOccurrences

Hello Aspose team,

I am trialing your Network components (x64, v4.8.0.12) and am having a very strange problem. If I run the following code, I get no dates generated:

Dim recur As New Aspose.iCalendar.RecurrencePattern("DTSTART:20090301T100000" + Environment.NewLine + "RRULE:FREQ=WEEKLY;COUNT=10;BYDAY=FR")
Dim recurDates As Aspose.iCalendar.DateCollection = recur.GenerateOccurrences()

However, if I change the year as follows from 2009 to 2004, it works fine:

Dim recur As New Aspose.iCalendar.RecurrencePattern("DTSTART:20040301T100000" + Environment.NewLine + "RRULE:FREQ=WEEKLY;COUNT=10;BYDAY=FR")
Dim recurDates As Aspose.iCalendar.DateCollection = recur.GenerateOccurrences()

It seems that no matter what date or rrule I use, if I specify a 2009 start date, the GenerateOccurrences method does not return any dates; however, if I set the start date to 2004, it works fine. What am I doing wrong? Is this a limitation of the trial version of the product?

Thanks!


This message was posted using Aspose.Live 2 Forum

Hi,

Thanks for considering Aspose.

The trial version limits the range of generated occurrence dates to December 31, 2004. To get a fully functional 30 days temporary license, please visit http://www.aspose.com/corporate/purchase/temporary-license.aspx.

After setting the license, you can set your desired date range. Please refer to http://www.aspose.com/documentation/.net-components/aspose.network-for-.net/licensing.html for instructions about setting the license.