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

invisible characters in InstallShield installer build logfile

When I run InstallShield 2010 Premier in command-line mode on Windows XP to build my installer project, InstallShield creates a text logfile. I use grep in cygwin to look for strings in the logfile. But it turns out that there is a ^@ character between each real character in the file. So my greps fail. Why are there ^@ characters spread out throughout my logfile? Here's an example. If I run "cat -v logfile", I see:

^@B^@u^@i^@l^@d^@i^@n^@g^@ ^@C^@A^@B^@ ^@f^@i^@l^@e^@s^@.^@.^@.^@^M^@
^@D^@a^@t^@a^@1^@.^@c^@a^@b^@ ^@b^@u^@i^@l^@t^@^M^@
^@F^@i^@l^@e^@s^@ ^@b^@u^@i^@l^@t^@^M^@

In a text editor like vi or wordpad, it looks normal like this:

Building CAB files...
Data1.cab built
Files built

Is there some way for me to tell InstallShield to create a normal text file?

Thanks.

Mark
Labels (1)
0 Kudos
(3) Replies
MichaelU
Level 12 Flexeran
Level 12 Flexeran

That sounds like you're seeing UTF-16 bytes treated as ANSI or latin-1 -- the ^@ are presumably nul bytes that occupy the upper half of most English characters in UTF-16. If cygwin has iconv, you can convert it in a pipe before your grep. Or use notepad or many other programs to convert it to UTF-8 or ANSI.
0 Kudos
mark_drobo
Level 2

Thanks Michael. iconv did the trick. Any reason why InstallShield is using encoding UTF-16 for my Win XP Pro system? As far as I know, this is just a regular English-only system. What is it querying in the system that makes it use UTF-16? Thanks.
0 Kudos
MichaelU
Level 12 Flexeran
Level 12 Flexeran

It's part of the enhanced Unicode support for IS2010, I believe. Since the files and strings output in the log can contain non-English characters, and more importantly, a mix of many characters which might not be on the default code page, the file is now ready to store this.
0 Kudos