Hello,

i used the Reverse Engeneering plugin to generate database code and jsp pages.

JSP Pages 
-------------
i added a file called "messages.properties" to the WEB-INF/classes folder 
In the jsp pages i can acces the ResourceBundle and a message will be displayed 
for the el- expression "msg.Member_country"



  | <f:loadBundle basename="messages" var="msg" />
  | <h:outputLabel value="#{msg.Member_country}" for="country">
  |     <h:inputText value="#{memberEditor.instance.country}" id="country" />
  |     <span class="rvgMessage"><h:message for="country" /></span>
  | </h:outputLabel>
  | 




JAVA-SIDE
------------
In my generated Classes i have the following statement:

  | @In
  | private transient ResourceBundle resourceBundle;
  | 

Well i think what the code above should do:
Use the ResourceBundle loaded by the jsp page.
I can load the Resourcebundle "manually" again in the bean,
but as far i understood seam , this i what seam can do for me becourse it has 
already bean loaded and it can be injected.

Did i understood this right? Pls correct me when i am wrong.

If i leave this code unchanged i get an exception from seam 
anonymous wrote : 
  | Caused by: org.jboss.seam.RequiredException: In attribute requires value 
for component: memberEditor.resourceBundle

well as workaround i changed the code to :

  | @In(create = true)
  | 

but that not really what i need, i need the same resourcebundle as used from 
jsp.

Do u see any possebility how to do this ?(If not ill load it "old fashioned 
way")

Thank u very much,

Holger

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3953153#3953153

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3953153

Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to