I am using WIX Installer in which i have a custom action as below.

 <CustomAction Id="ConfigureBiodentifyServer" FileKey="Biodentify.InstallUtil.exe" Execute="deferred" ExeCommand="/configurebiodentify /metadata=&quot;DefaultSetup.xml&quot; /iskiosk=&quot;false&quot;/databaseType=&quot;SQLServer&quot; /sqlserver=&quot;[$(var.SqlServerName)]&quot; /sqluser=&quot;&quot; /sqlpw=&quot;&quot; /domainName=&quot;[$(var.ComputerDomain)]&quot; /domainPk=&quot;[$(var.DomainPk)]&quot; " Impersonate="yes"  Return="check" />


<InstallExecuteSequence><Custom Action="ConfigureBiodentifyServer" After="StartServices">NOT Installed And $(var.InstallType) = "SERVER" </Custom>  </InstallExecuteSequence>

But the ExeCommand is giving error when i installed my Installer?

有帮助吗?

解决方案

There are several levels of refactoring you should be considering. First, you are calling InstallUtil which means you are calling an Installer class custom action. This custom action should be refactored to WiX Deployment Tools Foundation (DTF) to take advantage of a better hosting pattern ( for example you can Get/Set Windows Installer properties instead of passing command line arguments ).

Also WiX has SQL extensions to handle SQL Scripts so you might be reinventing the wheel here.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top