struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dana Hata <estesp...@141.com>
Subject RE: struts repopulate bug?
Date Wed, 05 May 2004 01:15:12 GMT
I keep coming across that as I google around for this.  The simple
answer is, I don't know.  All I know is that I am setting the 'input'
parameter for the action to the path to my JSP. I hope that answers your
question.  If not, how do I find out?

Dana

On Tue, 2004-05-04 at 21:26, Barett McGavock wrote:
> Are you redirecting to the JSP?
> 
> B
> 
> > -----Original Message-----
> > From: Dana Jeffrey Hata [mailto:estespark@141.com] 
> > Sent: Tuesday, May 04, 2004 5:36 PM
> > To: struts-user@jakarta.apache.org
> > Subject: struts repopulate bug?
> > 
> > 
> > I'm using Struts with WSAD, and I am attempting something 
> > very simple, which should happen automagically.  Basically, I 
> > just need to have the form re-populate after submitting a 
> > form which doesn't pass the form bean's validate method.  
> > Should happen without any special coding from me, as this is 
> > supposed to be a feature of struts.  Well, it didn't happen 
> > for me.  I checked things like form-bean scope.  By plugging 
> > in some strategically placed System.outs, I realized that 
> > struts was creating a new formbean object, and populating it, 
> > but when it came back to my JSP, that was using a different 
> > formbean object.  Shouldn't it be getting the form bean which 
> > (should have been) placed in the request/session by the 
> > actionservlet?  Well, it apparently wasn't, because the way I 
> > got it to work was simply putting the following line at the 
> > end of my formbean validate():
> > 
> > request.setAttribute(<my formbean name>,this);
> > 
> > This made everhything work, so my question is, why the hell 
> > didn't struts do this?  Isn't it supposed to?  Is there 
> > anything I could have done to make struts not do this, or 
> > maybe place a different form bean instance on the request?  
> > It works now, but I don't like hacks.
> > 
> > Thanks in advance,
> > Dana 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message