Could someone you give me a simple example of a bean being declared in the Action class that IS NOT an ActionForm and then accessed in the JSP <bean:write .../> tag? The ActionForm maintenance seems to be pretty straight-forward, but I'm dealing with plenty of objects that don't directly relate to forms (such as summary data) that I would like to pull up in the Action class and set so the <bean:write .../> can access it (in a report format).
Thanks, Michael Hedgpeth -----Original Message----- From: Ted Husted [mailto:[EMAIL PROTECTED]] Sent: Sunday, January 20, 2002 8:47 AM To: Struts Users Mailing List Subject: Re: Beginner questions The Struts bean tags do not require the useBean read tape, and it is rare for a Struts application to ever need to do this :) Struts is designed to encourage architectures based on the MVC paradigm. Generally, we recommend that all the beans be created and properties set by an Action object (org.apache.struts.Action) before forwarding control the presentation page. The page should just be outputing data, and shouldn't to do any additional processing. That's the Action's job :) -- Ted Husted, Husted dot Com, Fairport NY USA. -- Building Java web applications with Struts. -- Tel +1 585 737-3463. -- Web http://www.husted.com/struts/ Ronan-Yann LORIN wrote: > > Hi all, > > Excuse me if those questions looks stupid, I've seeked the documentation but > couldn't find the answer. > > 1) How do I write the following lines with struts: > <jsp:useBean id="logonForm" class="app.LogonForm" scope="request" /> > <jsp:setProperty name="logonForm" property="*" /> > I tried to create the bean the following way without success: > <bean:define id="logonForm" type="app.LogonForm" scope="request" /> > and how to set all it's properties from parameters? > > 2) How do I set a bean's property from an other bean property? (something > like "logonForm.username = argv.utilisateur") > > Thanks in advance for your help > Ronan-Yann Lorin > Banque AGF > Direction des Op�rations, Service Informatique > t�l : 01 44 86 27 99 > fax : 0 811 013 002 > m�l : [EMAIL PROTECTED] -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

