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

Delete Occurrence in a appointment recurrence

1 Answer 58 Views
ScheduleView
This is a migrated thread and some comments may be shown as answers.
Robi
Top achievements
Rank 2
Robi asked on 18 Feb 2014, 02:26 PM
Hi,
In my scheduleviewer you can create an appointment recurrence and this will be saved in the database (see attached file). it will save all needed information from the recurrence in the db. Now the problem is, if someone deletes an occurrence during the appointment recurrence, it will appear again in the scheduleview, beacause in the database the series is saved as one entity. my solution is, to split the saved recurrence in two. But for this I need the start and end date from the deleted occurrence. now my question is, how can I get the start and end date from the deleted occurrence, to create two (or more) reccurrences..?? Maybe with an scheduleView_Event.. ??

Regards,
Rob

1 Answer, 1 is accepted

Sort by
0
Yana
Telerik team
answered on 21 Feb 2014, 01:01 PM
Hello Rob,

I would suggest that you save the exceptions in a separate tables as in our Database example, you can check the used in the example schema in this help topic. Note that the exceptions can be of two types:
  • when an occurrence of a recurrent appointment is deleted -in this case you could save only the exception date.
  • when an occurrence of a recurrent appointment is edited - you should save all the properties of the exception separately, that is why we have in the example SqlExceptionAppointments, SqlExceptionResources tables.

When an occurrence is edited/deleted, the AppointmentEditing/Edited events of the parent appointment are fired, so you could use them to update the database. More information on the ScheduleView events can be found here.

I hope this helps.

 
Regards,
Yana
Telerik
Tags
ScheduleView
Asked by
Robi
Top achievements
Rank 2
Answers by
Yana
Telerik team
Share this question
or