Sweet....

Now are you telling me that the two html form can be on the same page?

What about pre-loading the select boxes with information?

On Nov 13, 2003, at 10:43 AM, Saul Q Yuan wrote:

Ok, then,

1. Let's say you declare your form as MyForm, which is of type
"DynaValidatorActionForm" in Struts-config.xml.

2. And you declare your actions as /myAction1 and /myAction2
respectively.

3. Then in validation.xml, declare your validation as:

<form name="/myAction1">
        <field ... >
          <arg0 ... />
        </field>
</form>

<form name="/myAction2">
        <field ... >
          <arg0 ... />
        </field>
</form>

4. Add necessary codes in your jsp files to support client side JS
validation.
        a.
         <html:form action="/myAction1.do" onsubmit="return
validateMyForm(this);">
        b.
                                <html:javascript formName="/myAction1"
method="validateMyForm" dynamicJavascript="true"
staticJavascript="false" />
                                <script language="Javascript1.1"
src="staticJavascript.jsp"></script>


same for the other jsp page.



Hope this helps


Saul


-----Original Message----- From: Nathan Maves [mailto:[EMAIL PROTECTED] Sent: Thursday, November 13, 2003 12:23 PM To: Struts Users Mailing List Subject: Re: simple design question

This sounds like what I need! Can you explain a little more.. :)

Thanks in advance,
nathan

On Nov 13, 2003, at 10:10 AM, Saul Q Yuan wrote:

Then a simple answer, one solution would be, use a single form, two
actions, and use action (path) based validation.


Saul




-----Original Message-----
From: Nathan Maves [mailto:[EMAIL PROTECTED]
Sent: Thursday, November 13, 2003 12:02 PM
To: [EMAIL PROTECTED]
Subject: simple design question


I have a simple design question..



I have to forms.


first form is one simple select box that needs to have the values
populated from a db.
This form needs to have validation and the submit to the second form.

The second form need to populate a select box based on the value from
the first form.  This form also need to be validated and then forward
on to the display jsp.

How many form beans and actions will I need?  I would like to use
dynavalidatorforms as well.


Current setup is an action that places an arraylist into an attribute of the request then forward to the first form. I dont know how to get the first form to auto validate and forward to the second form.

nathan


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to