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

BeginDrag and CustomAppointmentFactory in RadScheduler

3 Answers 105 Views
Scheduler and Reminder
This is a migrated thread and some comments may be shown as answers.
Andreas Haeusler
Top achievements
Rank 2
Andreas Haeusler asked on 18 Dec 2014, 09:43 AM
I recently upgraded an application from 2014 Q1 to the most recent 2014 Q3 release.
Now I experience a change in behaviour regarding drag + drop.

On every BeginDrag the RadScheduler triggers the IEvent CreateNewAppointment() in our CustomAppointmentFactory which in turn creates (unwanted) records in a database. Is this the expected/neccessary behaviour or can it be reverted to the old behaviour?

Kind regards,
Andreas

3 Answers, 1 is accepted

Sort by
0
Accepted
Dimitar
Telerik team
answered on 23 Dec 2014, 06:47 AM
Hello Andreas,

Thank you for writing.

Please note that we made a lot of improvements in our scheduler control in Q2 2014. In this particular case this is the default behavior and it is not recommended to change it (every time a new appointment is created the AppointmentFactory class should be used). In addition this is not a proper place to add the appointments to the database (you cannot be sure that the appointment is actually added to the scheduler, and you will have a blank appointment since it is just created). To track such changes you can use the respective events of the scheduler (AppointmentAdded, AppointmentDeleted) or you can use the Appointments.CollectionChanged event.

I hope this information helps.

Regards,
Dimitar
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Andreas Haeusler
Top achievements
Rank 2
answered on 05 Jan 2015, 12:55 PM
Hello Dimitar,


sorry for the late response (holidays blah blah)....

Your suggestion regarding the event AppointmentAdded is greatly appreciated -- we need to create the Database entries as early as possible (multi- user environment, each time slot can be used only once), prior to Q2 2014 the AppointmentFactory was only triggered when an Appointment was actually created (not during drag/drop). But as you wrote, the event AppointmentAdded works. So that's where we moved the code to and all is good.

Thanks.


Kind regards,
Andreas
0
Dimitar
Telerik team
answered on 06 Jan 2015, 07:34 AM
Hello Andreas,

Thank you for writing back.

I am glad I could be of help. Let us know if you have any other questions.
 
Regards,
Dimitar
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
Scheduler and Reminder
Asked by
Andreas Haeusler
Top achievements
Rank 2
Answers by
Dimitar
Telerik team
Andreas Haeusler
Top achievements
Rank 2
Share this question
or