2 Replies Latest reply on Apr 18, 2013 7:25 AM by Michal Petrov

    Richfaces 4.2 Calendar How to write a date string to the imput field by JavaScript?

    sanyika Newbie

      I have to copy a date string to the Calendar using JavaScript.


      With calendar id="renewal_date_input", the following code does not work:


      document.getElementById('AddressDetails:renewal_date_input').value = renewalDateCombo.value.toString();



      although I can read out the previously written String with:

           alert("written date is: " + document.getElementById('AddressDetails:renewal_date_input').value);

      but the Calendar input field does not show the string, it is just empty.

      Manual Input is also enabled: enableManualInput="true"

      What can I do?

      Thank you for your help.