Hi Manfred, I have given null="false" for my main module struts config file and still the error message is not displayed
instead it is just dipaying like below ????en.us.error.user.user_name.required.???? (It is just displaying property but not value) Thank you very much --Venkat -----Original Message----- From: Manfred Wolff [mailto:[EMAIL PROTECTED] Sent: Mon 6/13/2005 1:47 PM To: Struts Users Mailing List Cc: Subject: Re: Can struts-1.1 support multiple configurations and multiple resources Venkat I think you don't have to deal with suffixes (like sub) because struts itsselfs concatinate the module in the key, stored into the session. I have a little example written for my struts book (only in german) that deals with multiple struts config files. You may download it under http://struts-ge-packt.de/download/code.zip Because it is no maven project it comes with a lot of libraries. 1st Struts config: (struts-config.xml) <message-resources parameter="MessageResources" null="false" /> 2nd Struts config with Module (struts-modul-confix.xml) <message-resources parameter="MessageModulResources" /> It is a struts 1.2 application but the module support is fine in 1.1 -Manfred Venkat Reddy Valluri wrote: >Hi Manfred, > Thank you very much for responding immediately. I ended up multiple > struts config files successfully. But the thing is when I tried to use > separate resources for each struts config file using bundle parametre, It > seems not to be working. > >Here is my struts configurations > > In my main module struts config file >I included below one >struts-main.xml---> > <message-resources > parameter="com.main.examp.ApplicationResources"/> > > >In my sub module struts config file > >I included below one >struts-sub.xml---> > <message-resources > parameter="com.sub.examp.SubResources" key="sub"> ></message-resources> > >SubResources.properties------------> >error.user.user_name.required=UserName is required > >Here in my sub module > >SubEditActionForm.java---> > >In validate method I have given like this > >public ActionErrors validate(ActionMapping mapping, > HttpServletRequest request) { > ActionErrors errors = new ActionErrors(); > > if (user_name == null || user_name.length() == 0) { > errors.add("user_name", new > ActionError("error.user.user_name.required")); > } > return errors; > } > >But here the error messgae "UserName is required" is not able to be displyed >on screen when I submit the page with out entering user_name > > So I thought of passing buddle attribute "sub" which is used > struts-sub.xml to ActionError class >( ><message-resources > parameter="com.sub.examp.SubResources" key="sub"> ></message-resources>) > > But there is no option to pass that attribute in ActionError or > ActionMessage class > > SO here where I struck > >Can you please throw some light on this > >Thanks in advace > >--Venkat > > > > > > > > > > >-----Original Message----- >From: Manfred Wolff [mailto:[EMAIL PROTECTED] >Sent: Mon 6/13/2005 10:00 AM >To: Struts Users Mailing List >Cc: >Subject: Re: Can struts-1.1 support multiple configurations and multiple >resources > >Yes it can with multiple module support. > >http://struts.apache.org/userGuide/configuration.html#dd_config_modules > >Manfred > >Venkat Reddy Valluri wrote: > > > >>Hi >> >> Can struts-1.1 support multiple configurations and multiple resources. Can >> some body please throw some light on this. I need it very urgent >> >>Thanks in advance >> >>--Venkat >> >> >> >>------------------------------------------------------------------------ >> >>--------------------------------------------------------------------- >>To unsubscribe, e-mail: [EMAIL PROTECTED] >>For additional commands, e-mail: [EMAIL PROTECTED] >> >> >> > > > > -- =========================================== Dipl.-Inf. Manfred Wolff Software Engineer ------------------------------------------- http://www.manfred-wolff.de http://www.struts-it.org ------------------------------------------- Die fatale Neigung der Menschen, vom Nachdenken über eine Sache nachzulassen, wenn sie nicht länger zweifelhaft ist, ist die Ursache der Hälfte ihrer Irrtümer. - John Stuart Mil - ___________________________________________________ --------------------------------------------------------------------- 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]