Date Time Picker Max Date issue

3 posts, 1 answers
  1. Phanindra
    Phanindra avatar
    3 posts
    Member since:
    Oct 2013

    Posted 09 Jul 2014 Link to this post

    Hi i am using this code  
    it is working fine if i set MaxDate or MinDate time as 9:00,5:00,(One hour Difference)
    It doesn't work if i set Max time or MinTime in minutes  (9:45) (Manual Entry )

                       var maxDate = new Date(reqJobDate[0].EstEndDate);
                        var minDate = new Date(reqJobDate[0].StartDate);
                        rdpWOItemStartDate.set_maxDate(new Date(maxDate.getTime()));
                        rdpWOItemStartDate.set_minDate(new Date(minDate.getTime()));
                        rdpWOItemEndDate.set_maxDate(new Date(maxDate.getTime()));
                        rdpWOItemEndDate.set_minDate(new Date(minDate.getTime()));
                        rdpWOItemStartDate.set_selectedDate(new Date(rdpWOItemStartDate.get_minDate()));
                        rdpWOItemEndDate.set_selectedDate(new Date(rdpWOItemEndDate.get_maxDate()));
  2. Answer
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 09 Jul 2014 in reply to Phanindra Link to this post

    Hi Phanindra,

    Please have a look into the below code snippet which works fine at my end.

    <telerik:RadDateTimePicker ID="rdatetimepickerStartDate" runat="server">

    function pageLoad() {
        var rdpWOItemStartDate = $find("<%=rdatetimepickerStartDate.ClientID%>");
        var maxDate = new Date(2014,07,07,9,45);
        var minDate = new Date(2014,07,01,5,03);
        rdpWOItemStartDate.set_maxDate(new Date(maxDate.getTime()));
        rdpWOItemStartDate.set_minDate(new Date(minDate.getTime()));
        var selectedDate = rdpWOItemStartDate.get_minDate();

  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Phanindra
    Phanindra avatar
    3 posts
    Member since:
    Oct 2013

    Posted 09 Jul 2014 in reply to Shinu Link to this post

    Thanks Srinu It is Working
Back to Top