This is fine as long as the tag you're using the <bean:write.../> is not
another custom tag e.g. <html:.../> or <logic:.../> etc. It is done like
this:

<input type="submit" value="<bean:write name="FormName"
property="Property"/>" /> - make sure you include '/' at the end of the bean
tag.


If you want to use this in a custom tag you're going to have to define a
bean first and then use a jsp expression so you can set the value like so:

<bean:define id="prop" name="FormName" property="Property"/>

<html:option value="<%= prop %>"/>


hope this answers your question

claire :)

----- Original Message -----
From: "Mailing List" <[EMAIL PROTECTED]>
To: "'Struts Users Mailing List'" <[EMAIL PROTECTED]>
Sent: Thursday, January 29, 2004 10:53 AM
Subject: Using "bean:write" as a tag's value atrribute


>
> Dear All;
>
> Using <bean:write name="myBeanName" property="its property"> works
properly
> in my jsp page body. But when I want to use it in a tag to fill its
> attribute, it fails.
>  Actually I don't know the syntax of using bean:write, obviously the below
> way is wrong:
>
> <someTag value="<bean:write name="myBeanName" property="its property">">
>
> Using expression is wrong, too:
>
> <someTag
>      value="<%=<bean:write name="myBeanName" property="its property">%>">
>
> So how could I use bean:write in my tags?!
>
> Any help would be greatly appreciated
> Nafise
>
>
> ---------------------------------------------------------------------
> 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