I have a date field: lastModDate I am using dynaForms and have the following form:
<form-bean name="metricForm" type="org.apache.struts.validator.DynaValidatorForm"> .... <form-property name="lastModDate" type="java.util.Date" /> </form-bean> My display of the form works fine. I can see the value...there are no type issues. When I try to save the value I get the following error: ============================================================ javax.servlet.ServletException: BeanUtils.populate org.apache.struts.util.RequestUtils.populate(RequestUtils.java:1254) org.apache.struts.action.RequestProcessor.processPopulate(RequestProcessor.java:821) org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:254) org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482) org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:525) javax.servlet.http.HttpServlet.service(HttpServlet.java:763) javax.servlet.http.HttpServlet.service(HttpServlet.java:856) com.sbc.netrics.struts.database.HibernateFilter.doFilter(HibernateFilter.java:40) root cause org.apache.commons.beanutils.ConversionException: Cannot assign value of type 'java.lang.String' to property 'lastModDate' of type 'java.util.Date' org.apache.struts.action.DynaActionForm.set(DynaActionForm.java:423) org.apache.commons.beanutils.PropertyUtils.setSimpleProperty(PropertyUtils.java:1769) org.apache.commons.beanutils.PropertyUtils.setNestedProperty(PropertyUtils.java:1684) org.apache.commons.beanutils.PropertyUtils.setProperty(PropertyUtils.java:1713) org.apache.commons.beanutils.BeanUtils.setProperty(BeanUtils.java:1019) org.apache.commons.beanutils.BeanUtils.populate(BeanUtils.java:808) org.apache.struts.util.RequestUtils.populate(RequestUtils.java:1252) org.apache.struts.action.RequestProcessor.processPopulate(RequestProcessor.java:821) org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:254) org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482) org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:525) javax.servlet.http.HttpServlet.service(HttpServlet.java:763) javax.servlet.http.HttpServlet.service(HttpServlet.java:856) com.sbc.netrics.struts.database.HibernateFilter.doFilter(HibernateFilter.java:40) ==================================================================== In my form I have the value stored in a hidden field: <html:hidden property="lastModDate"/> When I "view source" I see my date value in the hidden field. The error I get happens before anything my my process form method. If I take out the hidden field, the error goes away -- but then I don't have my date value in the form field. Lee --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]