Unable selection of future dates and flexible changing of ye

Hi all,

I am just wondering if it possible to set the dthmlxcalendar so that it won’t allow selection of future dates but only past dates. And is it also possible to allow user to directly change the year and month? For example, i would like to use dhtmlxcalendar as a calendar for user to select their birth dates. So it can be a hassle if i have to click the arrows back many years later. Any solution? Thanks

selection of future dates but only past dates

calObj.setSensitive(null,new Date());

dhtmlx.com/docs/products/dhtmlxC … 4249376000


Thanks for the answer. Anyway it works except for this link of code:
mCal2 = new dhtmlxCalendarObject(‘dhtmlxCalendar2’, false, {isYearEditable: true,isMonthEditable: true});

Mine would only work if it was:
mCal2 = new dhtmlxCalendarObject(‘dhtmlxCalendar2’, true, {isYearEditable: true,isMonthEditable: true});

Not sure why though, but thanks anyway.

In first case you will need to add
to render calendar object, in second case it is executed automatically while construction.
Both ways of init are valid.

Oh okay, i didn’t know that. Thanks!