I am using radscheduler, I need to select multiple dates from the month view of scheduler, I would like to get start date and end date of my selection.
How is that possible in C#?
It is urgent therefore a quick response would be greatly appreciated.
Thanks
1 Answer, 1 is accepted
0
Accepted
Ivan Danchev
Telerik team
answered on 24 Jun 2016, 08:19 AM
Hello Jalil,
The selection of timeslots is not available on the server. You can get it on the client by subscribing to the Scheduler's OnClientTimeSlotClick event and calling the Scheduler's get_selectedSlots() method:
function OnClientTimeSlotClick(sender, args) {
var slots = sender.get_selectedSlots();
var start = slots[0].get_startTime();
var end = slots[slots.length - 1].get_endTime();
$telerik.$("#HiddenFieldStart").val(start);
$telerik.$("#HiddenFieldEnd").val(end);
}
The get_selectedSlots() method returns a collection of the selected TimeSlots. You can then get the first slot's StartTime and the last slot's EntTime and save them into hiddenfield controls: