wood burning stoves*
The moose likes Struts and the fly likes message resource file Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "message resource file" Watch "message resource file" New topic
Author

message resource file

Neeraj Vij
Ranch Hand

Joined: Nov 25, 2003
Posts: 315
Hi,

Is it possible to assign the value of a key specified in message resource files to a variable ?

I need something like this..

<c:set var="test" value="<bean:message key='gdHome.sectionheader.topheader' bundle='gdCommon'/>" />


Thanks,
Neeraj
Merrill Higginson
Ranch Hand

Joined: Feb 15, 2005
Posts: 4864
You can set a variable using the body of the <c:set> tag.

Try this:

<c:set var="test"><bean:message key='gdHome.sectionheader.topheader' bundle='gdCommon'/> </c:set>


Merrill
Consultant, Sima Solutions
Neeraj Vij
Ranch Hand

Joined: Nov 25, 2003
Posts: 315
thanks.. it worked for me..

Regards,
Neeraj.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: message resource file
 
Similar Threads
DynaValidatorActionForm not working
Struts Validator: Blank JS Alerts
Struts validation with minlength
Setting value for a key programmatically for arg0 tag
Unable to validate Mask attribute