Hi Hilario, I am extremely thankful for your constant replies and from your previous reply I was quite able to understand how XLAT can be used for generating different locale specific resources. I was able to build it and generate all the file using it.But the limitation with this approach is that I need to re-compile the xerces c++ lib every time when-ever I want to use error messages for different locale.
"With your approach I will generate different locale specific file replace the EN_US file and then finaly replace the content of MsgLoaders\Win32\version.rc file with the content generated by XLAT." Then re-compile the xerces lib? And it should work. "But if I need any different locale then will I need to recompile the xerces lib? Or only replacing the content of version.rc will be sufficient" Actually I want to avoid this re-compile xerces lib step as it doesn't solve my purpose. So my question is there already in build infrastructure in place that can solve my need Or I need to modify xerces code. Or I need to write a module above xerces that can do this job. If you have understood my question right then it should be my last query regarding this particular problem, to this mailing list :). You have been a great help, I understand It must be hard to spare time. With Best Regards Gaurav Sharma -----Original Message----- From: Hilario Perez Corona [mailto:[email protected]] Sent: Tuesday, November 09, 2010 10:30 PM To: [email protected] Subject: Re: localized error messages Ok, i've just changed from EN_US to ES_MX... It's very straightforward, you only need to make an XML with your different languages, and then read the README file that comes with Xlat, it'll tell you exactly what to do. After that, just change your preprocessor defines on the xerces project... Mine was: XERCES_USE_MSGLOADER_INMEMORY You can change it to ICU or whatever you like... And recompile. On Mon, Nov 8, 2010 at 11:01 PM, Sharma, Gaurav < [email protected]> wrote: > Hi All, > > Can any one provide me some information about xerces c++ error messaging > infrastructure. I want to keep xerces c++ error message files for different > locales as dll resource and load any one of them based on the locale pass > into the xerces initialize function. I don't want to compile xerces static > lib again and again. > > Kindly provide some inputs. > > With Best Regards > Gaurav Sharma > > -----Original Message----- > From: Hilario Perez Corona [mailto:[email protected]] > Sent: Tuesday, November 02, 2010 12:04 PM > To: [email protected] > Subject: Re: localization help--Please reply > > You need to translate and create your own XMLErrList_**_**.xml file for > japanese. > > I just copied the original english XML and translated it with google, then > manually fixed the translation problems... > > If you need 2 or more languages that change dynamically while running, then > you would need to write a module that can switch between those two > languages. > > But, if you only need 1 language (like me), just replace the EN_EN files > with your JP file. Just name it the same, recompile and it should work. > > I just downloaded XLat, but i haven't compiled it (if would be cool if > Xerces provide binary downloads for the tools), it's not a priority for me > right now, but i need to do it before the end of the week... 'till then, > hope this info helps you. > > > > On Mon, Nov 1, 2010 at 10:09 PM, Sharma, Gaurav < > [email protected]> wrote: > > > Hi Hilario, > > > > Thanks a lot for your reply. I still need to ask some questions from you. > I > > hope you have seen my queries below, I just wish to know that- are you > also > > willing to perform same thing. What I want to do is--that once I > initialize > > xerces c++ with some locale say "japanese" than on any occurrence of > error > > the returned error message should be in Japanese. I am currently trying > to > > build xerces 3.1 using windows and vc8. If you know what are the exact > steps > > to resolve my problem than kindly suggest me. > > > > Also from the reply of Alberto to your question, I am not able to > > understand how you will generate the XMLErrList_ES_ES.Xml for your > specific > > need. I have xlat tool with me, I assume I can build it using cygwin on > > windows. Once I build it how will I generate XMLErrList_**_**.Xml for any > > specific locale and then how to use it for my purpose. > > If you can help me then most welcome and thanks a lot in advance. I don't > > know why any one else also reply for the same :(. > > > > With Best Regards > > Gaurav Sharma > > > > -----Original Message----- > > From: Hilario Perez Corona [mailto:[email protected]] > > Sent: Tuesday, November 02, 2010 3:59 AM > > To: [email protected] > > Subject: Re: localization help--Please reply > > > > Maybe the question i made would help you... > > > > I found some ICU headers on Xlat code searching on the net info for > Xlat... > > > > > > > https://svn.osgeo.org/fdo/tags/3.3_S033/Thirdparty/apache/xml-xerces/c/tools/NLS/Xlat/ > > > > On Fri, Oct 29, 2010 at 3:15 AM, Sharma, Gaurav < > > [email protected]> wrote: > > > > > > > > Hi All, > > > > > > After searching a lot I have now been trying to generate > > > xercesc_messages_3_1.dll that would have this entry point > > > xercesc_messages_3_1_dat, using pkgdata.exe manually, but it is unable > to > > > find root.res file. I don't know what it is. It no where present in > whole > > > xerces code. Can any one help me. Please also read the below two mails > > and > > > let me know if I have been doing the right thing. > > > > > > With Best Regards > > > Gaurav Sharma > > > > > > -----Original Message----- > > > From: Sharma, Gaurav [mailto:[email protected]] > > > Sent: Thursday, October 28, 2010 7:27 PM > > > To: [email protected] > > > Subject: RE: localization help--Please help > > > > > > Hi All, > > > I look around on net and found this link > > > http://marc.info/?l=xerces-c-users&m=112497911319278 that talks about > > > building xercesc++ with ICU. I am stuck now at one linking error that > > > "unresolved symbol for __imp__XercesMessages3_1_dat. I am unable to > > resolve > > > it. > > > One more thing I would like to know that - are the error messages for > > > different languages embeded with in the xerces lib ? or these can be > > > distributed speratly as dlls and later linked with the application that > > uses > > > xerces lib, depending on the locale. > > > Please help me:) > > > > > > With Best Regards > > > Gaurav Sharma > > > > > > ________________________________________ > > > From: Sharma, Gaurav [[email protected]] > > > Sent: Thursday, October 28, 2010 8:55 AM > > > To: [email protected] > > > Subject: RE: localization help > > > > > > Hi Boris and All, > > > > > > Could you please elaborate a bit more on it? Form your message it looks > > > like I need to build the xerces c++ libraries myself and configure it > as > > per > > > my needs. Is it the case? Currently I am using downloaded libs/dll. > > > > > > Thanks and Regards > > > Gaurav Sharma > > > > > > > > > -----Original Message----- > > > From: Boris Kolpackov [mailto:[email protected]] > > > Sent: Tuesday, October 26, 2010 7:27 PM > > > To: [email protected] > > > Subject: Re: localization help > > > > > > Hi Gaurav, > > > > > > Sharma, Gaurav <[email protected]> writes: > > > > > > > Does anyone has any idea about whether or not xerces provides > > > > infrastructure for the localized error messages. What my need is that > > > > if I set the locale by any mean to "Chinese" while initializing > xerces > > > > then the error message returned from xerces should be Chinese. > > > > > > Yes, you can configure Xerces-C++ with one of the more advanced message > > > loaders (e.g., ICU or MsgCatalog) which will allow you to load > different > > > message catalogs depending on the locale/language. You will need to > > > study the interface/source code for the message loader of your choice > > > to figure out how to do this. > > > > > > Boris > > > > > > -- > > > Boris Kolpackov, Code Synthesis > > > http://codesynthesis.com/~boris/blog > > > Compiler-based ORM system for C++ > > > http://codesynthesis.com/products/odb > > > Open-source XML data binding for C++ > > > http://codesynthesis.com/products/xsd > > > XML data binding for embedded systems > > > http://codesynthesis.com/products/xsde > > > The information contained in this electronic mail transmission > > > may be privileged and confidential, and therefore, protected > > > from disclosure. If you have received this communication in > > > error, please notify us immediately by replying to this > > > message and deleting it from your computer without copying > > > or disclosing it.The information contained in this electronic mail > > > transmission > > > may be privileged and confidential, and therefore, protected > > > from disclosure. If you have received this communication in > > > error, please notify us immediately by replying to this > > > message and deleting it from your computer without copying > > > or disclosing it. > > > > > > > > > > > > The information contained in this electronic mail transmission > > > may be privileged and confidential, and therefore, protected > > > from disclosure. If you have received this communication in > > > error, please notify us immediately by replying to this > > > message and deleting it from your computer without copying > > > or disclosing it. > > > > > > > > > > > > > > > -- > > Hilario Perez Corona > > "No Religion Higher Than Truth" > > The information contained in this electronic mail transmission > > may be privileged and confidential, and therefore, protected > > from disclosure. If you have received this communication in > > error, please notify us immediately by replying to this > > message and deleting it from your computer without copying > > or disclosing it. > > > > > > > > > -- > Hilario Perez Corona > "No Religion Higher Than Truth" > The information contained in this electronic mail transmission > may be privileged and confidential, and therefore, protected > from disclosure. If you have received this communication in > error, please notify us immediately by replying to this > message and deleting it from your computer without copying > or disclosing it. > > > -- Hilario Perez Corona "No Religion Higher Than Truth" The information contained in this electronic mail transmission may be privileged and confidential, and therefore, protected from disclosure. If you have received this communication in error, please notify us immediately by replying to this message and deleting it from your computer without copying or disclosing it.
