This is a migrated thread and some comments may be shown as answers.

Recurrence Exceptions

1 Answer 95 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Stuart Hemming
Top achievements
Rank 2
Stuart Hemming asked on 17 Nov 2010, 03:12 PM
I'd be grateful of someone could just fill in the blanks for me here (Assume I'm doing all the form handling myself)

I have a recurring appointment. The user opts to edit it.

I catch the Form_Creating event and cancel it. I open my own form.

I call PrepareToEdit() to get the appointment to edit. The user has opted to create a new recurrence exception.

The user updates the details and presses Save.

I call UpdateAppointment() (yes?) What appointment do I pass to it, the original (the recurrence Master) or the new one (the Exception)?

I know I need to handle RecurrenceExceptionCreated but I'm unsure what, if anything, /I/ need to do to ensure this is called and that the EventArgs are properly populated.

Is RecurrenceExceptionCreated raised as a result of me calling UpdateAppointment?

Enquiring minds, an all that

-- 
Stuart

1 Answer, 1 is accepted

Sort by
0
Veronica
Telerik team
answered on 23 Nov 2010, 11:18 AM
Hello Stuart Hemming,

Please accept my apologies for the late reply.

After you select the "Edit only this occurence" option from the "Editing a recurring dialog" pop-up then in the UpdateAppointment() method you will edit the exception and not the master. After pressing Save - the OnRecurrenceExceptionCreated event will be fired. Here's a sample structure of a master appointment and exception in xml:

<Appointment>
    <ID>23</ID>
    <Subject>recurrence master</Subject>
    <Start>2010-11-22T09:30Z</Start>
    <End>2010-11-22T10:30Z</End>
    <RecurrenceRule><![CDATA[DTSTART:20101122T093000Z
DTEND:20101122T103000Z
RRULE:FREQ=MONTHLY;COUNT=3;INTERVAL=1;BYSETPOS=-1;BYDAY=MO,TU,WE,TH,FR
EXDATE:20101130T093000Z
]]></RecurrenceRule>
  </Appointment>
  <Appointment>
    <ID>29</ID>
    <Subject>recurrence exception</Subject>
    <Start>2010-11-30T09:30Z</Start>
    <End>2010-11-30T10:30Z</End>
    <RecurrenceParentID>23</RecurrenceParentID>
  </Appointment>

Please note that in the "recurrence exception" appointment the ID of the master is kept in the RecurrenceParentID. That way you can refer to the master if needed.

We plan to extend the "External Edit in RadDock" demo so that user will be able to create recurring appointments. I'll attach the extended demo as soon as it's ready.

Please let me know if you have more questions.

Kind regards,
Veronica Milcheva
the Telerik team
Browse the vast support resources we have to jumpstart your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
Tags
Scheduler
Asked by
Stuart Hemming
Top achievements
Rank 2
Answers by
Veronica
Telerik team
Share this question
or