我有一个WiX软件包,安装后应用程序启动:
<Property Id="WIXUI_EXITDIALOGOPTIONALCHECKBOXTEXT" Value="Launch MyProgram" />
<Property Id="WIXUI_EXITDIALOGOPTIONALCHECKBOX" Value="1" />
<Property Id="WixShellExecTarget" Value="[#MainExe]" />
<CustomAction Id="LaunchApplication" BinaryKey="WixCA" DllEntry="WixShellExec" Impersonate="yes" />
我想将WiX包的语言传递给我的程序。有可能吗?
答案 0 :(得分:8)
有效:
<Property Id="WIXUI_EXITDIALOGOPTIONALCHECKBOXTEXT" Value="Launch" />
<Property Id="WIXUI_EXITDIALOGOPTIONALCHECKBOX" Value="1" />
<Property Id="LANGUAGE" Admin="yes" />
<CustomAction Id="LaunchApplication"
FileKey="MainExe"
ExeCommand="[LANGUAGE]"
Execute="immediate"
Impersonate="yes"
Return="asyncNoWait" />
<!-- icon for add/remove programs -->
<Property Id="ARPPRODUCTICON" Value="ProgramIcon.exe" />
<!-- Интерфейс пользователя (подключается отдельной сборкой) -->
<UI Id="MyWixUI_Mondo">
<UIRef Id="WixUI_Minimal" />
<Publish Dialog="ExitDialog" Control="Finish" Event="DoAction" Value="LaunchApplication">WIXUI_EXITDIALOGOPTIONALCHECKBOX = 1 and NOT Installed</Publish>
<UIRef Id="WixUI_ErrorProgressText"/>
</UI>