struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject 2 problems that are just driving me CRAZY
Date Wed, 05 Jun 2002 02:55:01 GMT

I'm having two problems which are sure to drive me out of my mind if I don't
find the solution soon.  If you can help with either one of these, I would
appreciate it.

1) For my problem, let's say I have 2 actions with 2 forms called ActionA,
ActionB, FormA, and FormB.  ActionA is going to use FormA and ActionB is
going to use FormB.  But, for some reason, the jsp which displays FormB
actually tries to display FormA.  I know this because FormA has an attribute
called transactionMonth and FormB has an attribute called monthSelection.
When I try to run this, I get an exception which tells me that there is no
getter for monthSelection.  However, if I go into my jsp and change it to
transactionMonth (from Form A), it works without a hitch.  ActionB does get
FormB though.  I know this because if I do a "servlet.log(form);" in
ActionB, I get the full pathname for FormB.  This problem occurs when I
forward to ActionB/FormB (not when I do a submit, I haven't tried that yet).

2) My second problem I've had trouble with longer.  It has to do with
ActionErrors and using the <html:errors/> tag.  In one branch of my webapp,
this works just fine.  But, for no reason that I can see, along another
branch of my webapp, the error message is not displayed.  I do the exact
same thing in both cases: I detect an error, add it to the errors
collection, do a SaveErrors method call, and forward using getInput().  In
both cases, the input form is re-displayed, but in one case the error
message is displayed and in the other case it's not.  The only other
discrepency that I see, which is also annoying, is that in the case where
the error does display, the input fields get cleared and they are all blank.
In the case where the error message is not dispalyed, the input fields
contain the values which were entered prior to the submit.

Thanks for your help,

Mike Witt

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message