I want to restrict user to enter multiple entries per day in week view scheduler. It should be only one entry. It should not create additional row. I am attaching sccreenshot of my requirement in this post. Please guide me to achive this. (I am using Resource group also in this case)
1 Answer, 1 is accepted
0
Accepted
Boyan Dimitrov
Telerik team
answered on 22 Jan 2015, 12:48 PM
Hello,
An easy way to restrict user to insert more than one appointment for a day is to use the OnFromCreating event handler:
1. When you double click on a time slot the RadScheduler FormCreating will be fired.
2. The e.Appointment will have start and end time of the clicked time slot.
3. Once you have the appointment start time ( respectively this is the clicked time slot start time) you know for which date user is trying to insert an appointment.
4. The RadScheduler GetAppointmentsEnclosingRange method retrieve all appointments enclosed in the range. This way you can check if there are any appointments scheduled for this specific day.
5. If there are already - you can set e.Cancel = true and prevent showing the advanced from.
Regards,
Boyan Dimitrov
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.