Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

getting error with bean:message tag

 
Kumar Sushil
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I am using <bean:message> tag, but it is not accepting any dynamic value for arg.

<bean:message bundle="product.loader" key="gfasload.already1" arg0="<bean:write name ='loadInvestmentForm' property='code'> </bean:write>"/>

If i write out side <bean:write name ='loadInvestmentForm' property='code'> </bean:write> the its giving me value, but inside <bean:message/> not giving.

thanks in advance.
 
Kumar Sushil
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can any body help me on this?
 
Sagar Rohankar
Ranch Hand
Posts: 2907
1
Java Spring Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Actually I`m too not able to find out solution for it ..

like many time I want to display the results in input field ,
so in struts I ended up writing something like this ,



but this wont compile , So I need to write something like as classic html



this complies and works fine ..

May be If you are loading this page after action executes , we can save the message with the key and display on jsp page with <html:messges/> tag .

Does that help ?
 
Kumar Sushil
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for reply.
Actually I want use <bean:message> and as you are aware that for using <html:message> we required to write code in action classes also, that is not with <bean:message>.
 
Sagar Rohankar
Ranch Hand
Posts: 2907
1
Java Spring Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Where are you creating this bean , loadInvestmentForm ?
Set this bean in request attribute and then use
runtime expression or JSTL tags like <jsp:useBean > or {loadInvestmentForm.code} in arg0=" " ..

Try this,
 
Kumar Sushil
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When I try outside arg0 <bean:write> tag, it is working fine. I think in <bean:message> with args some problem. We can pass only hard code value or we required with run time expression. With JSTL also. nothing happend
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic