Hello, I'm using Aspose.Email version 3.6.0.0. I've found an issue with the RecurrencePattern.GenerateOccurrences(int nextNOccurrences) method. If no end date or count is specified in the pattern, the method never returns. I never get an exception so I'm not sure what's wrong, but the method seems to go on forever.
If I use the GenerateOccurrences(DateTime rangeStart, DateTime rangeEnd) overload with the same RecurrencePattern object, it works fine. However, I need to use the nextNOccurrences method sometimes just to generate the next 2 occurrences.
Could you please look into the code below and let me know why this happens? I can work around it but I would also like to know why it happens, so I can anticipate it in other use cases.
public void GetOccurrencesDailyAsposeTest()
{
RecurrencePattern asposeProvider = new RecurrencePattern();
asposeProvider.StartDate = new DateTime(2014, 2, 12);
RecurrenceRule rule = asposeProvider.RRules.Add();
rule.Frequency = Frequency.Daily;
rule.Interval = 3;
DateCollection predictedDates = asposeProvider.GenerateOccurrences(2);
}
Thank you,
Nicole