Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
45
Help Identifying Appointments in a Series
posted

I need to do some processing on the appointments that belong to a series (regardless whether they are variances or not), and I am having a hard time finding who they are programmatically.  I understand that the 'recurrence' object exposes certain properties such as DayOfMonth, Period, PeriodMultiple, etc. that determine the characteristics of the series but I need to get the specific values and their combinations to make sense of these numbers.  I wonder if anybody has come across a table with those values?  I have explored the source code for those values but have not gotten too far.

Any help would be appreciated.

Thanks,

AntonioL 

Parents
  • 310
    posted

    I don't know if there is another way, but here is how i did it.

     

    Instantiate a FrameInterval object and pass it to the BasicRecurrenceEngineFactory.

    FrameInterval recurrenceInterval = new FrameInterval(this.WebScheduleInfo, root.Recurrence.StartDateUtc, root.Recurrence.EndDateUtc);

    RecurrenceEngine recurrenceEngine = BasicRecurrenceEngine.RecurrenceEngineFactory(root.Recurrence, recurrenceInterval);

    while (recurrenceEngine.MoveNext())
    {
       // recurrenceEngine.CurrentActivity will advance through all of the Occurrences
    }

     

    You can specify different dates in the FrameInterval constructor if you have a narrow date range that you are interested in.

     

Reply Children