cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
tintop
Level 2

Display unicode code points glyph

Hi Everyone,

I am wondering how to take a property that contains unicode code points such as: C:\logs\/u3042/u3057/u3074/u3073 and display it on a dialog in its glyph form: C:\logs\あしぴび

Is there some way to get that translated in InstallShield or do I need to read the property containing the code points into a custom action, translate it, then write the translated string to a property to display?

Thanks in advance.
Labels (1)
0 Kudos
(3) Replies
MichaelU
Level 12 Flexeran
Level 12 Flexeran

If your property contains escape characters (i.e. it literally contains a slash or backslash, a u character, and 4 hex number characters), you will need to unescape it into the actual Unicode characters. If it already contains the Unicode characters, you should be fine.

It's unclear from the rest of your post what languages you are considering for conversion; the Unicode support in InstallScript setups was improved in InstallShield 2011, but even so it may be good enough for your needs so long as you can call, e.g., MsiSetPropertyW instead of MsiSetPropertyA (I believe the latter was the default before 2011).
0 Kudos
tintop
Level 2

Hi MichaelU,

I'm working with InstallShield 2010 and a basic msi project.

The property literally is in the form: "C:\logs\/u3042/u3057/u3074/u3073"
It is read from the registry during a system search and is the path to a folder we need to use during the installation process. On English only systems, not a problem. No international characters should be present, but we sell our product to the international community and the registry value will contain Japanese and other non-ASCII characters in the above format.

Sounds to me your suggesting I'll need to read it into a custom action that will normalize it then write it back into a database property. I was hoping there was some way to get it "normalized" when it was read from the registry during the system search.

Thank You for the response.
0 Kudos
MichaelU
Level 12 Flexeran
Level 12 Flexeran

Right, if you need to convert from "C:\logs\/u3042/u3057/u3074/u3073" to "C:\logs\あしぴび" you'll need to do that in a custom action. Windows Installer comes with only very rudimentary conversions, primarily between integer (say REG_DWORD) and string (properties). However if you can just store "C:\logs\あしぴび" in the registry and read that value, then no conversion is necessary and things should just work in a Basic MSI.
0 Kudos