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

Dynamic Context Menus on Load

2 Answers 55 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Mangesh
Top achievements
Rank 1
Mangesh asked on 23 Nov 2012, 08:17 PM
Hi there,

I wanted to load context menus based on dynamic conditions.
For example
1) In scheduler If there are some appointments in some specific slot, there should be option like "Cancel All Appointments". And If there is no appointment for that slot, then there should be option like "Add New Appointment" as Context Menus.
2) Suppose I set some disabled slot for some slots in scheduler by cssClass and now I wanted to show context menu option "Make Available" only to those slots?

Is there any way I achieve this functionality? any reply in short time will be appreciated.

Thanks in advance,

Mangesh

2 Answers, 1 is accepted

Sort by
0
Boyan Dimitrov
Telerik team
answered on 28 Nov 2012, 04:34 PM
Hello,

An easy and convenient way to achieve the described scenario would be to check in the OnClientTimeSlotContextMenu event handler for any appointments in that time slot.
Getting the DOM element for the clicked time slot and check if has attribute with your custom class will show your context menu that contains "Make available" option.
Please find attached a sample project that demonstrates the desired functionality implemented by using three different RadContextMenus depending on different conditions.

Hope that this will lead you into right direction.

Regards,
Boyan Dimitrov
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0
Pankaj
Top achievements
Rank 1
answered on 08 Jun 2018, 09:55 AM

TimeSlotContextMenuItemClicked is not getting raised in this scenario.

How do I handle it?

Tags
Scheduler
Asked by
Mangesh
Top achievements
Rank 1
Answers by
Boyan Dimitrov
Telerik team
Pankaj
Top achievements
Rank 1
Share this question
or