I think you are confused. You still need to declare your <form-bean> in struts-config.xml using 'type='org.apache.struts.validator.DynaValidatorForm'. In your validation.xml the <form-set>....</form-set> is used by validator to identify the properties from your <form-bean> so that validator will know what kind of validation to perform. Struts, as far as I know, will NOT instantiate anythiing simply by being in the validation.xml file.....
Jerry > -----Original Message----- > From: Hohlen, John [mailto:[EMAIL PROTECTED]] > Sent: Friday, September 27, 2002 1:54 PM > To: Struts-Help (E-mail) > Subject: HELP!: Pre-populating A DynaValidatorForm in Struts 1.1 B2 > > > Does anyone know how to instantiate a "DynaValidatorForm" > declared in the > "validation.xml" file within Java code? > > <formset> > <form name="employeeForm"> > <field property="emailAddress" > depends="required,email"> > <arg0 key="general.emailAddress"/> > </field> > <field property="anniversaryDate" > depends="required,date"> > <arg0 key="general.anniversaryDate"/> > <var> > <var-name>datePatternStrict</var-name> > <var-value>MM/dd/yyyy</var-value> > </var> > </field> > </form> > </formset> > > More specifically, I want this form, used by my JSP, to contain > pre-populated data from the database. Therefore, it is > desired to have my > action to instantiate the form bean and pre-populate it -- > versus letting > the Struts framework create one with default values. In > Struts 1.0, I just > did the following in my action: > > EmployeeForm employeeForm = new EmployeeForm(); > > But this won't work using dyna forms in Struts 1.1 since there is no > "EmployeeForm" Java class. > > Thanks! > > > -- > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: > <mailto:[EMAIL PROTECTED]> > > This transmission (and any information attached to it) may be confidential and is intended solely for the use of the individual or entity to which it is addressed. If you are not the intended recipient or the person responsible for delivering the transmission to the intended recipient, be advised that you have received this transmission in error and that any use, dissemination, forwarding, printing, or copying of this information is strictly prohibited. If you have received this transmission in error, please immediately notify LabOne at (800)388-4675. -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

