Regarding Dhtmlx Calendar with image

Hi All,

i am working on Dhtmlx calendar with image. when i click on the image calendar pop up is opening and selected date is displaying on the text box. but if i modify any date in the text box it is not setting on the calendar popup… please help me in this…

Please find my attached code :

Jsp Code:


function init()
asOfDate = new dhtmlxCalendarObject(‘asofdateTs’);
asOfDate.attachEvent(“onClick”, selectAsOfDate);
document.getElementById(‘asOfDate’).value = asOfDate.getFormatedDate(“%d %b %Y”) ;
function selectAsOfDate(date) {
document.getElementById(‘asofdateTs’).value = " “;
var dateFormat = asOfDate.getFormatedDate(”%d %b %Y", date);
document.getElementById(‘asOfDate’).value = dateFormat;
return true;


asOfDate = new dhtmlxCalendarObject(‘asofdateTs’); such an initialization can be used if you attach calendar to the text input. If calendar is open on button click, you need to use another way of intialization:

  1. calendar should be initialized in the absolutely positioned container.
  2. its visibility is changed by display = “none” / “”
  3. date is set and get setFormatedDate / getFormatedDate methods (when the calendar is shown, you may call setFormatedDate to set value from the input to the calendar).

Please see the sample: