Problem with calendar button on web

I have a button that I use to call a date picker using show_calendar.js. The button works fine when the form is first created. After I save the form and exit, if I go back to the form I saved and click on the button I get an object expected error message (see below).

Button on-click code: show_calendar(‘document.forms[0].txt_date_req.value’);

script debugger: Date CR Opened on Infoman <img src=“/evelyn/EmergencyChangeRequest.nsf/cal.gif?OpenImageResource” width=“8” height=“9” align=“middle” class=“CalCols” onclick=";

THIS IS HIGHLIGHTED ON DEBUGGER show_calendar(‘document.forms[0].txt_cr_open_dte.value’); END OF HIGHLIGHT

" alt=“”>

Date Required on Infoman:

Subject: Problem with calendar button on web

Hi,

I think that javascript (JS) don’t “see” the field “txt_cr_open_dte”

When you have this error, your document is in read mode?

In this case, check “Generate HTML for all fields”* in form properties (second tab), thus Domino will generate a INPUT tag with TYPE=“hidden” for all fields and JS will “see” these fields…

*becarefull with this option, if you have many fields in form, it can slow down the load of page…

Thierry

Subject: RE: Problem with calendar button on web

I am able to edit other fields without a problem. The field is not hidden and the properties are set according to your response.