Re: Access to ApplicationResources.properties from Action class?

2001-03-13 Thread Mikael Eriksson
Your right of course. Seems that I answered the question a bit too quickly, my eyes focues on the code example and I lept to conclusions from that :-( Regards Mikael Martijn Spronk wrote: I think that the best thing to do would be to not use the text of the button at all. If you use

Access to ApplicationResources.properties from Action class?

2001-03-12 Thread Martijn Spronk
Hi all, I'm pretty new to struts, and just started developing a fairly simple app, however taking a bit beyond the standard example functionality. I have a (probably) pretty simple question: I'm in the perform method of the Action class, processing a form submit, but want to forward to

RE: Access to ApplicationResources.properties from Action class?

2001-03-12 Thread James Stephens
how to unsubscribe please -Original Message- From: Martijn Spronk [mailto:[EMAIL PROTECTED]] Sent: Monday, March 12, 2001 13:22 To: '[EMAIL PROTECTED]' Subject: Access to ApplicationResources.properties from Action class? Hi all, I'm pretty new to struts, and just started developing

Re: Access to ApplicationResources.properties from Action class?

2001-03-12 Thread Mikael Eriksson
Hello, I think that the best thing to do would be to not use the text of the button at all. If you use the text you will need to change the code as well if you decide to change the text on the button by editing the property file. (And if you get internationalization into the picture it will be

RE: Access to ApplicationResources.properties from Action class?

2001-03-12 Thread Martijn Spronk
From your action class you can call. MessageResources messages = getResources(); String message = messages.get(locale, "resource.key"); Thanks, that did the job. PS The method is getMessage(), not get(). --- Mikael Eriksson [EMAIL PROTECTED] wrote: Hello, I think that the best thing

Re: Access to ApplicationResources.properties from Action class?

2001-03-12 Thread Marty Fisher
Martijn, I'm also new to struts, could you post the relavent portion of your ApplicationResources.properties file for me. I'm interested in how your code works if you want to have the button be in French or whatever. Thanks, Marty Fisher Martijn Spronk wrote: From your action class you can

RE: Access to ApplicationResources.properties from Action class?

2001-03-12 Thread Martijn Spronk
I'm also new to struts, could you post the relavent portion of your ApplicationResources.properties file for me. I'm interested in how your code works if you want to have the button be in French or whatever. Sorry Marty, I am not using internationalization in any way. My properties file is

Re: Access to ApplicationResources.properties from Action class?

2001-03-12 Thread Maya Muchnik
David, Please clarify for me. I am trying use your application for validation and display different error depending on a selected language. It is 05 release. Your RegistrationAction.java or MultiRegistrationAction.java calls Locale locale = getLocale(request); but it is not used in the source