2011-02-18 32 views
2

好的我相信我遵循Wix3.5中的在線示例來執行安靜的命令,但我似乎無法讓我的命令被執行引用。CAQuietExec命令字符串必須以引用的應用程序名稱開頭

<Component Id="MapObjectsRuntime' Guid='*'> 
    <File Id = 'Mo23rtEXE' Name='Mo23rt.exe' Source='....' KeyPath="yes"/> 
<Component> 

<Property Id = "QtExecCmdLine" Value="Mo23rt.exe" /> 

// I've tried single & double quotes, and double double quotes around Mo23. 

<CustomAction Id = "InstallMapObjects" BinaryKey="WixCA" DllEntry="CAQuietExec" Execute="immediate" Return="check" /> 

<InstallExecuteSequence> 
    <Custom Action="InstallMapObjects" After="InstallFinalize">NOT Installed</Custom> 
</InstallExecuteSequence> 

我得到一個警告構建WiX工程: 文件Mo23rtEXE不是一個字體,它的版本是不是伴隨文件引用。

我還需要分配命令行參數到mo23rt.exe命令,但我第一個只是試圖讓這個工作。谷歌透露,很多人似乎也在爲此苦苦掙扎。

忘了補充一點,運行setup.exe的/ L * V install.log的有:

MSI Doing action: InstallMapObjects 
. 
. 
Property Change: Deleting QtExeCmdLine property. Its current value is 'Mo23rt.exe'. 
CAQuitExec: Command string must begin with quoted application name. 
CAQuietExec: Error 0x80070057 invalid command line property value 

回答

0

我曾試過「」mo23rt.exe「」和「'mo23rt.exe'」,對我沒有嘗試''mo23rt.exe''感到羞恥。其他東西仍然是錯的,但它可能是上面提到的,或者它可能是我試圖運行的東西,試圖建立一個狀態欄對話框,並不是很安靜。

+0

我建議使用包裝中「的和USIG [DIR] mo23rt.exe或[#fileKey]其中的FileKey的EXE的文件ID。這是更好地完全限定EXE路徑則認爲它會(它可能不會) – 2011-02-18 21:03:25

0

我將它更改爲常規自定義動作副CAQuiet。

<CustomAction Id="InstallMapObjects" FileKey="Mo23rtEXE" ExeCommand="/ACDJKLM" Execute="commit"/> 

followed by 

<InstallExecuteSequence> 
    <Custom Action="InstallMapObjects" Before="InstallFinalize">NOT Installed</Custom> 
</InstallExecuteSequence> 
相關問題