First of all, you are referring to the classic RadControls for ASP.NET, while the thread info says you are using RadCalendar for ASP.NET AJAX. I am assuming we are talking about the classic controls.
is a property of the client RadDatePicker object. The respective property for RadCalendar is SetRangeMaxDate()
2. Client RadCalendar object does not have a property names SetDate()
. Such a property is provided by RadDatePicker.
I believe you wanted to modify the max date and selected date of RadDatePicker. Now, with RadDatePicker, you are also using a RadDateInput (the textbox that displays the selected date). RadDateInput's client object also has its own MinDate and MaxDate property. When setting the MaxDate property of the picker, the new date is not updated as the MaxDate property of the date input. You need to manually set it:
picker = window[
'<%= datpick1.ClientID %>'
picker.DateInput.MaxDate = picker.GetMaxDate();
The above code works as expected now. Check it out.
the Telerik team