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

How do disable and enable several datetime pickers...

1 Answer 149 Views
Date/Time Pickers
This is a migrated thread and some comments may be shown as answers.
Michael
Top achievements
Rank 1
Michael asked on 14 Feb 2013, 07:51 PM
Is there an easy way to enumerate through a list of controls such as datetime pickers or numeric controls and call the enable() method on them without specifying the id? Essentially I want to disable and enable a group of controls in a div.

Thanks!

1 Answer, 1 is accepted

Sort by
0
Michael
Top achievements
Rank 1
answered on 14 Feb 2013, 08:01 PM
There may be an easier way to do this but here is what I came up with:
$("." + className + " input[type='date']").each(function () {
 
                    var datePicker = $("#" + this.id).data("kendoDatePicker");
 
                    if (datePicker) {
                        datePicker.enable();
                    }
                });
Tags
Date/Time Pickers
Asked by
Michael
Top achievements
Rank 1
Answers by
Michael
Top achievements
Rank 1
Share this question
or