fea jabi wrote:
When I debug after
DynaActionForm setupForm = (DynaActionForm) form;
my setupForm is null
Is your struts config as you posted earlier? i.e., the "name" attribute
refers to a Dyna form that doesn't exist in the "form-beans" section?
That won't work.
ModuleConfig moduleConfig =
RequestUtils.getModuleConfig(request,
getServlet().getServletContext());
FormBeanConfig formConfig =
moduleConfig.findFormBeanConfig("CustForm");
DynaActionFormClass dynaClass =
DynaActionFormClass.createDynaActionFormClass(formConfig);
try {
setupForm = (DynaActionForm)dynaClass.newInstance();
one of the user suggested that when I initialize a form-property in
struts-config using initial="true"
I have to use the above to prepopulate the form.
is this right?? Am I using at the right place.
If Struts is configured the form will have already been created on entry
to the Action.
I think you need to back up a step and check your configuration. If you
post the relevent sections again as they exist now we might be able to
help you better.
Right now things are wrong, and I find it highly unlikely you would
_ever_ need or want to instantiate a form inside an Action.
Dave
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]