1
我有一個簡單的應用程序,我正在安裝一個exe並在安裝結束時運行它。但是當安裝完成後,它顯示app.exe的第二個高程對話框,我不想顯示它,這裏是我的wix代碼。第二個高程對話框
<?xml version="1.0" encoding="UTF-8"?>
<!-- The following three sections are from the How To: Add a File to Your Installer topic-->
<Directory Id="TARGETDIR" Name="SourceDir">
<Directory Id="ProgramFilesFolder">
<Directory Id="APPLICATIONROOTDIRECTORY" Name="My Application Name"/>
</Directory>
</Directory>
<DirectoryRef Id="APPLICATIONROOTDIRECTORY">
<Component Id="app.exe" Guid="12345678-1234-1234-1234-222222222223">
<File Id="app.exe" Source="MySourceFiles\app.exe" KeyPath="yes" Checksum="yes"/>
</Component>
</DirectoryRef>
<Feature Id="MainApplication" Title="Main Application" Level="1">
<ComponentRef Id="app.exe" />
</Feature>
<!-- Step 2: Add UI to your installer/Step 4: Trigger the custom action -->
<InstallExecuteSequence>
<Custom Action='LaunchInstalledExe' After='InstallFinalize'/>
</InstallExecuteSequence>
<CustomAction Id="LaunchInstalledExe"
FileKey="app.exe"
ExeCommand=""
Return="ignore" />
非常感謝菲爾,這個伎倆。 –