Skip to Content
author's profile photo Former Member
Former Member

Internationalization not working with WDResourceHandler - IMPORTANT

Hi,

I have developed a Web Dynpro application. The requirement was to internationalize this application so that the UI Elements/Messages etc come in diff languages. The language required are Japanese, Chinese,French & Malay along with English.

Now i followed these links:

http://help.sap.com/saphelp_nw04/helpdata/en/44/f0674039c6c549e10000000a1550b0/frameset.htm

http://help.sap.com/saphelp_nw04/helpdata/en/e0/65f378cbc80d4390ea9283b7094dd6/frameset.htm

I tried changing the .xlf files. But here are the problems i am facing:

1) For translation, which the Web Dynpro does, it uses the WDResourceHandler. I have found that if i am having two iViews on this same Web Dynpro(which is my requirement to have multiple iViews on single web dynpro), and one is forced in Japanese & other Chinese, then whichever iView loads first , the second web dynpro iView takes the first web dynrpo iView locale. This means that the WDResourceHandler's locale gets cached. This is a serious problem. Since if u have a look at the standard UI element of TableView, the word "Line 1 of 1" also does not gets changed dynamically if the locale is changed. You have to logoff to see the changed locale. Any help on this will be appreciated....

2) In the S2X editor, i am not able to type/paste in Japanese & chinese. i am using NWDS 2.0.9, Does any body knows how to use the editor for these languages.

3) Malay Language is not available in the languages dropdown of S2X editor. Does anybody knows how to get Malay.

Though a long list of problem, but these problems have become serious now for our aplication bcos of the failure of WDResourceHandler. Any kind of help and suggestion would be rewarded and appreciated.

Regards

Gaurav Gandhi

Add a comment
10|10000 characters needed characters exceeded

Related questions

3 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Aug 23, 2005 at 11:19 AM

    Hi Gaurav

    Generally when a webdynpro application runs, It takes the default locale of the browser. I guess you will not be able to display content in 2 different languges on the same page.

    Regards

    NagaKishore V

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi NagaKishore,

      Thanks for the reply. This is what i have found during my application build. But this is bad. I am now really stuck due to this limitation.

      We can use portal to show web dynpro and in portal you can change the portal language and everything gets reflected and changed dynamically but this is not applicable with web dynpro bcos the WDResourceHandler does not picks it up dynamically.

      If you or any body else can provide any other clue or any workaround for this, i will really be happy..

      Hope to see some workarounds...

      Regards

      Gaurav Gandhi

  • Posted on Aug 23, 2005 at 12:18 PM

    hi,

    you have to do the following steps :-

    • Internationalization is used for adapting already existing Webdynpros application

    Without changing the source code so that they can be used in several multi lingual languages.

    • Here we keep text strings separately from the application source code in a particular format(keys & values) so they can be processed in the standard translation mechanism.

    • Here frequently used texts such as labels or titles are stored as java dictionary simple types objects.

    • To do internationalization, copy the automatically generated *.xlf files and save them under the new name in the same directory.

    • For eg :- file convention like <old filename>_<language key>.xlf. Ex:- For German use the language key de.

    • For a particular user the locale is specified by the User management engine.

    • If not the locale is handled by the browser setting(HTTP Headers)

    • If not the default locale specified by the application will be returned.

    • If not default locale of the Virtual Machine(VM) is returned

    • This locale is passed to java.lang.ResourceBundle in the J2EE engine.

    • This will load the physically existing resource bundle either from any one of the following :-

    Resource bundle of WD(if exists) or resource bundle of VM (if exists) or

    Resource Bundle of without language suffix(always exists) given by the developer.

    Hope it helps.

    Regards,

    Guru

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Aug 25, 2005 at 05:06 AM

    Hi Gandhi,

    did you put the property file in the package structure of your project.Are you also reading it from the property file which will be a key-value pair like a HashMap.

    Also are you using java.util.resourcebundle for the same.

    Refer these blogs by my colleague which will definitely help you.

    /people/perumal.kanthan/blog/2005/05/26/application-internationalization-in-sap-webas-using-java-resource-bundlepart-ii

    /people/perumal.kanthan/blog/2005/06/09/application-internationalization-in-sap-web-as-using-java-resource-bundle-part-iii

    Regards,

    Guru

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Guru,

      Thanx for the link of PART-III link. I had already read the Part-I & Part-II when it was released (i didnt knew when this guy released PART-III?).

      Actually why i was stressing on the .xlf way is because it is mentioend (and even i tried) that it is very simple abd i dont have to do any coding. Just keep on making .xlf files and that will work automatically.

      But now i am so much frustrated with this appraoch, am now planning to do full fledged coding and use the resource bundles and develop langauge based UI.

      I will now definately look at these and try to solve my problem. If i face some problem on this i will let u know.

      Regards

      Gaurav Gandhi

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.