[wix-users] Installer Localization

Andreas Buchner Andreas.Buchner at inloox.com
Tue May 9 08:40:22 PDT 2017

For a case where we needed a (default) system account I implemented a solution to translate the user from the default sid within a custom action.


// convert the user sid to a domain\name
var account = new SecurityIdentifier(sid).Translate(typeof(NTAccount)).ToString();

That should help :-)

-----Ursprüngliche Nachricht-----
Von: wix-users [mailto:wix-users-bounces at lists.wixtoolset.org] Im Auftrag von Jason Groshart
Gesendet: Dienstag, 9. Mai 2017 17:09
An: wix-users at lists.wixtoolset.org
Betreff: [wix-users] Installer Localization

I need help with how to resolve a localization issue.  I have a product installer that creates and then installs a database.  We are using SqlScript to execute a complex SQL script that creates and fills in all the initial tables and data like so:

          <sql:SqlScript Id="dbInstallScript.NamedInstance.WindowsAuthentication"
                         ContinueOnError="no" />

The SQL script includes an installation of the System Account Name, which varies based on local.  Some of these locations include special characters, for example:

       SET @sysAccountName = 'NT AUTHORITY\SYSTEM'

       IF (@defaultLanguage = 'Deutsch')
              SET @sysAccountName = 'NT-AUTORITÄT\SYSTEM'
       IF (@defaultLanguage = 'Français')
              SET @sysAccountName = 'AUTORITE NT\Système'

The special character in the German language SAN, Ä, has caused us some issue.  We get an error message where the character is displayed as either '�'or 'A,,'.  I recognize this as character encoding issues and I found some information that there is a known issue where WIX SqlScript does not support UTF-8 encoding.  This is supposed to be fixed in a 3.x version, but has not yet been resolved.  So, I saved the .sql script as full UTF and also updated the WIX xml encoding to utf-16 like so:

<?xml version="1.0" encoding="utf-16"?>

This resolved the issue on the German system that it was originally reported and we installed fine.  I thought we'd resolved the issue.  However, we try installing on a different German system and we again see the encoding issue with the error showing 'A,,'.  I've verified that the previous fixes are in place, but they are not working on this system.  I suspect that this is an issue caused by different systems and OS possibly related to endian issues.  Currently we don't set Codepage and I'm wondering if I need to do something with that, but I don't know if that makes a difference or how to set it.  The installer itself can be in English, so 1033 Language works for us, but I need the SQL script to properly recognize the special character.

Any help or advice you can provide on this issue would be welcome.  Thanks.


WiX Toolset Users Mailing List provided by FireGiant http://www.firegiant.com/

More information about the wix-users mailing list