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

Kendo Scheduler - Unselect a selected event programatically

5 Answers 749 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Lloyd
Top achievements
Rank 1
Lloyd asked on 31 Mar 2016, 07:42 AM

How do I unselect a selected event programmatically? I tried to call the select() method with an empty array input but it doesn't seem to unselect the events. Further, I see that the change event is invoked only once as opposed to twice in the Chrome console window.

Please see the below code snippet for an example.

http://dojo.telerik.com/Exiyo

Thanks in advance.

 

 

5 Answers, 1 is accepted

Sort by
0
Lloyd
Top achievements
Rank 1
answered on 03 Apr 2016, 11:18 PM

This functionality is really critical for our application. Are there any updates or suggestions for this issue?

 

0
Accepted
Georgi Krustev
Telerik team
answered on 04 Apr 2016, 09:58 AM
Hello Lloyd,

You can clear the selection passing 'null' to the select method: Let me know if this does not help.

Regards,
Georgi Krustev
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Martin
Top achievements
Rank 1
commented on 05 Aug 2022, 08:40 AM

Please document this behaviour! 

There is no mention of how to clear the selection on the scheduler API pages.

Martin
Telerik team
commented on 09 Aug 2022, 06:01 AM

Hi, Martin,

We will add a line in the select method API showing how to clear the selection.

0
Lloyd
Top achievements
Rank 1
answered on 05 Apr 2016, 03:04 AM
It works now! Thank you!
0
K.Ramadan
Top achievements
Rank 2
Veteran
answered on 29 Jul 2020, 07:28 AM

Hi there,

I know I am a bit late, but passing the value null to the Method select(), it is working only when I trigger this in the Scheduler_Navigation Function. But what I am trying to do, is to trigger the select() Method after Canceling the Editor.

 

So this is what I did in the Scheduler_Cancel Function AND in the Scheduler_Navigation Function :

 

var scheduler = $("#schedulerEvent").data("kendoScheduler");
scheduler.select(null);

 

It's deselecting the Selected Slots only when i navigate, but when i cancel the Editor, it is just changing the selected Slots from more than one Slot to the FIRST SLOT ON THE LEFT SIDE

0
Ivan Danchev
Telerik team
answered on 30 Jul 2020, 07:07 PM

Hello,

Indeed in this scenario the Scheduler selects the first slot in the view. You can remove the k-state-selected class from the slot with jQuery:

scheduler.select(null);
setTimeout(function() {
  $('.k-scheduler-content td.k-state-selected').removeClass('k-state-selected');
}, 0);

Regards,
Ivan Danchev
Progress Telerik

Tags
Scheduler
Asked by
Lloyd
Top achievements
Rank 1
Answers by
Lloyd
Top achievements
Rank 1
Georgi Krustev
Telerik team
K.Ramadan
Top achievements
Rank 2
Veteran
Ivan Danchev
Telerik team
Share this question
or