[wix-users] Check for existing instance and notify user

Pete DiBetta pdibetta at onestreamsoftware.com
Fri Feb 11 14:25:04 PST 2022


Hi,

We just implemented command line support for multi-instance installations in our installer.  This appears to be working correctly.  The issue is if a user specifies an existing instance on the command line (i.e. already installed).  In that case, a Windows Installer 'Invalid command line argument' error occurs and the user is presented with the associated error dialog.  It would be preferable to identify that the specified instance is already installed and provide the user with a more descriptive error message.  I assume this is fairly common scenario but I am VERY new to Wix and Windows installer and have not been able to find a good example of how to handle this.

I tried searching the archive prior to sending this but the search is not working as of this writing.  My sincere apology if this has been asked and answered previously.  Any guidance would be very much appreciated.

The log shows the following...

=== Verbose logging started: 2/11/2022  16:35:09  Build type: SHIP UNICODE 5.00.10011.00  Calling process: C:\windows\system32\msiexec.exe ===
MSI (c) (EC:88) [16:35:09:104]: Font created.  Charset: Req=0, Ret=0, Font: Req=MS Shell Dlg, Ret=MS Shell Dlg

MSI (c) (EC:88) [16:35:09:104]: Font created.  Charset: Req=0, Ret=0, Font: Req=MS Shell Dlg, Ret=MS Shell Dlg

MSI (c) (EC:B8) [16:35:09:120]: Resetting cached policy values
MSI (c) (EC:B8) [16:35:09:120]: Machine policy value 'Debug' is 0
MSI (c) (EC:B8) [16:35:09:120]: ******* RunEngine:
           ******* Product: Setup.msi
           ******* Action:
           ******* CommandLine: **********
MSI (c) (EC:B8) [16:35:09:122]: Machine policy value 'TransformsSecure' is 0
MSI (c) (EC:B8) [16:35:09:122]: User policy value 'TransformsAtSource' is 0
MSI (c) (EC:B8) [16:35:09:122]: Machine policy value 'DisableUserInstalls' is 0
MSI (c) (EC:B8) [16:35:09:122]: Specified instance {40C455AD-0128-4E5D-917B-BD4BD361EE73} via transform  is already installed. MSINEWINSTANCE requires a new instance that is not installed.
MSI (c) (EC:B8) [16:35:09:122]: MainEngineThread is returning 1639
=== Verbose logging stopped: 2/11/2022  16:35:09 ===

Thanks,

Pete


More information about the wix-users mailing list