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

[Solved] Disable Datepicker lateset version (Q3) doesn't work anymore

2 Answers 81 Views
Date/Time Pickers
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Gerard Eikelboom
Top achievements
Rank 1
Gerard Eikelboom asked on 04 Mar 2011, 10:28 AM
Hello,
I have a question about disabeling the datepicker.
We implemented this with the Q2 2010 release.
We used the code below and it always worked:
var IsChecked = $('#FutureDates').is(':checked');
    if (IsChecked) {
        var input = $('#TotDatum').find('> .t-input');
        input.attr("disabled", true);
        input.val('');
        input.css('background-color', '#DCDCDC');
        //$('#TotDatum-input').css('background-color', 'gray');
        $('#TotDatum > .t-icon').unbind('click')
        $('#TotDatum > .t-icon').bind('click', function () { return false; })
    }
What is does it also disables the textbox and the calender control.
This week we went to the latest version (2010 Q3) the method is hit.
But they are still enabled. Is this a known issue (if it is an issue) or did something changed?

Regards,
Gerard 

2 Answers, 1 is accepted

Sort by
0
Atanas Korchev
Telerik team
answered on 04 Mar 2011, 10:36 AM
Hi Gerard Eikelboom,

 
The supported way of disabling the datepicker is to call  the "disable" JavaScript method.

Regards,
Atanas Korchev
the Telerik team
Registration for Q1 2011 What’s New Webinar Week is now open. Mark your calendar for the week starting March 21st and book your seat for a walk through all the exciting stuff we ship with the new release!
0
Gerard Eikelboom
Top achievements
Rank 1
answered on 04 Mar 2011, 11:19 AM
Hi Atanas ,
A lot easier to use. Implemented it and works fine.

Regards,
Gerard Eikelboom 
Tags
Date/Time Pickers
Asked by
Gerard Eikelboom
Top achievements
Rank 1
Answers by
Atanas Korchev
Telerik team
Gerard Eikelboom
Top achievements
Rank 1
Share this question
or