struts-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joe Germuska <...@Germuska.com>
Subject Re: RE: FormBeans ... as an Interface.
Date Tue, 02 Jul 2002 20:20:01 GMT
At 4:03 PM -0400 2002/07/02, struts-dev@japache.org wrote:
>(I'm not proposing autopopulating anything -- the Action has to 
>fetch the value object anyway. I just want to reference it directly 
>using syntax like valueObject.name from my form tags... This 
>*avoids* aupopulating or having to synchronize any object since the 
>ActionForm just references the value object.)

You can do that, by specifying the optional "name" attribute of the 
form tags.  When you use that, the source of the property is changed 
from the default FormBean to whatever object is found with that name.

<html:text name="valueObject" property="name" ... />

It's easy to overlook this if you get used to the default behavior of 
the tags when "name" is not defined...  but it's pretty handy once 
you get used to it.

Joe

-- 
--
* Joe Germuska    { joe@germuska.com }
"It's pitiful, sometimes, if they've got it bad. Their eyes get 
glazed, they go white, their hands tremble.... As I watch them I 
often feel that a dope peddler is a gentleman compared with the man 
who sells records."
	--Sam Goody, 1956
tune in posse radio: <http://www.live365.com/stations/289268>

--
To unsubscribe, e-mail:   <mailto:struts-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-dev-help@jakarta.apache.org>


Mime
View raw message