Topic
1 reply Latest Post - ‏2008-05-08T12:21:52Z by SystemAdmin
SystemAdmin
SystemAdmin
11979 Posts
ACCEPTED ANSWER

Pinned topic [WSAD 5.1.2] Unicode Support in Resource file

‏2008-05-08T11:30:17Z |
Hi,

I am facing a peculiar problem with resource application file. I am not able to store Thai unicode characters in application_resource.properties file.

What I am trying to do?

I want to assign Thai equivalents to English labels used on web pages runtime using resource application file. When I save the above said file in unicode and run the application, I get garbage characters on screen. However, when I use static strings in Thai language, in same application, it is displayed properly along with English.

Is there a setting that need to be tweaked so this sort of assignment through resource application file works? Is there a way to get WYSIWYG in Eclipse, so it displays the resource file with English and their corresponding Thai equivalents.

Do I need any plugin to achieve this? Do I need any extra fonts?

I am using WSAD 5.1.2 for development of web application with struts 1.1. For development I am using a Windows 2000 Advanced Server edition.

TIA.

:wq Sam
Updated on 2008-05-08T12:21:52Z at 2008-05-08T12:21:52Z by SystemAdmin
  • SystemAdmin
    SystemAdmin
    11979 Posts
    ACCEPTED ANSWER

    Re: [WSAD 5.1.2] Unicode Support in Resource file

    ‏2008-05-08T12:21:52Z  in response to SystemAdmin
    Guys, sorry for hoax call. The problem is solved. Here is more information:

    http://www-1.ibm.com/support/docview.wss?rs=457&context=SSBRLP&context=SSSTY3&dc=DB520&dc=DB560&uid=swg21257640&loc=en_US&cs=utf-8&lang=en
    Text from this link --

    Cannot save Russian characters in property file

    Technote (FAQ)

    Problem

    In a Struts-based Web application using property files, developed with IBM® Rational® Application Developer installed on Microsoft® Windows®, Russian characters that are saved in a property file are converted to question marks (????), rendering them unusable.

    Solution

    The workaround for this problem in RAD on a Windows operating system is as follows:

    1. Use notepad to open a new text file and copy the Russian text into the file.

    2. Save the text file (for example, myRussian.txt) with the Unicode encoding option enabled.

    3. Convert the Russian characters to escape codes, using the following commands to be run within a command prompt:

    native2ascii -encoding unicode myRussian.txt mycodes.txt

    (The "native2ascii" utility should be available in any JDK.)

    4. Copy the escape codes from mycodes.txt into the property file.

    End text from link --

    :wq Strike.