cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
MVISION
Level 3

UNICODE and INI files

I am using IS2012Pro MSIBasic which is a bit more of an extra learning curve coming from Express than I expected.

My problem relates to UNICODE UTF-8 characters. I can create Reg entries, I can copy files successfully but when I try to change INI files I get rubbish. The INI file I am trying to alter is UTF-8 and retains it's existing UNICODE characters. The strings I want are displayed in the IS interface.

If I try to write an INI from scratch I am getting ANSI files created. This is different to what in in the RN for IS2011 where it says "Unicode Support for Files, Folders, Registry Entries, and Support Files. Unicode support has been added to key parts of the installation run time, enabling you to use characters from any languages simultaneously in file names, folder names, registry entries, and support file names. This enables you to install, for example, a file that has Japanese characters in its name or target path on an English system. Mixing languages works correctly regardless of the current language of the target system."
This is exactly what I want and why I spend my money but alas cannot get it to work for INI files.
Is it a bug?
Labels (1)
0 Kudos
(3) Replies
MichaelU
Level 12 Flexeran
Level 12 Flexeran

I know when programming against the common INI file APIs, in order to get a Unicode INI file you have to start with at least a Unicode file. (It can be just the BOM on an otherwise empty file, but as it is the INI File Changes view, I would suggest including a template INI that can be updated.) I'm uncertain whether the UTF-8 BOM is supported, or just the UTF-16-LE BOM.
0 Kudos
MVISION
Level 3

MichaelU wrote:
I know when programming against the common INI file APIs, in order to get a Unicode INI file you have to start with at least a Unicode file. (It can be just the BOM on an otherwise empty file, but as it is the INI File Changes view, I would suggest including a template INI that can be updated.) I'm uncertain whether the UTF-8 BOM is supported, or just the UTF-16-LE BOM.


😄 🙂 Many thanks Michael that did the trick. I was using a template INI file in UTF-8 BOM but converting the template INI to UCS-2 LE did the trick.

I can abandon the work-around editing the INI as a "text file" which did work but not so elegant.
0 Kudos
Sairen
Level 7

Can someone tell me for sure whether InstallShield 2012 does or does not support UTF-8 BOM?

Our development team selected that for our INI files, and it would be a colossal setback if that is not supported! Would there be any workaround short of asking the rest of the department to change formats? I can tell you this would not be palatable...
0 Kudos