Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/wix/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/angularjs/23.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
WIX复制通过加热获取的文件,但不创建cab文件_Wix_Windows Installer_Cab_Wix3.10 - Fatal编程技术网

WIX复制通过加热获取的文件,但不创建cab文件

WIX复制通过加热获取的文件,但不创建cab文件,wix,windows-installer,cab,wix3.10,Wix,Windows Installer,Cab,Wix3.10,对Wix来说是相当新的。我有一个正在工作的msi,但是msi文件旁边没有cab文件,我只是得到一个文件夹。我花了几天的时间试图弄明白为什么不把文件放在cab文件中,但我完全不知所措 msi文件的性能完全符合我的预期,但将msi与文件夹一起分发并不如仅将msi分发 <?xml version="1.0"?> <Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"> <Product Id="*" Name="[Nam

对Wix来说是相当新的。我有一个正在工作的msi,但是msi文件旁边没有cab文件,我只是得到一个文件夹。我花了几天的时间试图弄明白为什么不把文件放在cab文件中,但我完全不知所措

msi文件的性能完全符合我的预期,但将msi与文件夹一起分发并不如仅将msi分发

<?xml version="1.0"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<Product Id="*" Name="[Name]" Language="1033" Manufacturer="[Manufacturer]" Version="2.0.30" 
         UpgradeCode="af66ae21-61e4-4926-954d-ee89acf95ab3">
    <Package InstallerVersion="200"/>

    <MajorUpgrade DowngradeErrorMessage="A newer version of [Name] is already installed." />
    <MediaTemplate/>

    <Feature Id="ProductFeature" Title="[Title]" Level="1">
      <ComponentRef Id="ApplicationShortcut" />
      <ComponentRef Id="ApplicationShortcutDesktop" />
      <ComponentGroupRef Id="WebApp" />
      <ComponentGroupRef Id="ControlApp" />
    </Feature>
</Product>

<Fragment>
  <Directory Id="TARGETDIR" Name="SourceDir">
      <Directory Id="ProgramFiles64Folder">
        <Directory Id="ManufacturerName" Name="[Name]">
            <Directory Id="INSTALLLOCATION" Name="[Name]" />
        </Directory>
      </Directory>
      <Directory Id="ProgramMenuFolder">
    <Directory Id="ApplicationProgramsFolder" Name="[Name]"/>
    <Directory Id="DesktopFolder" Name="Desktop"></Directory>
  </Directory>
    </Directory>
</Fragment>
<Fragment>
<DirectoryRef Id="ApplicationProgramsFolder">
 <Component Id="ApplicationShortcut" Guid="844b584d-6d5f-4825-9541-c7caf74892fb">
   <Shortcut Id="ApplicationStartMenuShortcut" 
             Name="[Name]" 
             Description="[Name]" 
             Target="[INSTALLLOCATION]MyApp.exe" 
             WorkingDirectory="INSTALLLOCATION" />
   <RemoveFolder Id="RemoveApplicationProgramsFolder" Directory="ApplicationProgramsFolder" On="uninstall" />
   <RegistryValue Root="HKCU" Key="Software\[Name]" Name="installed" Type="integer" Value="1" KeyPath="yes" />
 </Component>
</DirectoryRef>   
<DirectoryRef Id="DesktopFolder">
 <Component Id="ApplicationShortcutDesktop" Guid="629d0ac6-8c63-4309-af33-975925584d1f">
   <Shortcut Id="ApplicationDesktopShortcut" 
             Name="[Name]" 
             Description="[Name]" 
             Target="[INSTALLLOCATION]MyApp.exe" 
             WorkingDirectory="INSTALLLOCATION" />
   <RemoveFolder Id="RemoveDesktopFolder" Directory="DesktopFolder" On="uninstall" />
   <RegistryValue Root="HKCU" Key="Software\[Name]" Name="installed" Type="integer" Value="1" KeyPath="yes" />
 </Component>
   </DirectoryRef>
  </Fragment>
</Wix>


包/@Compressed
属性设置为

漂亮!较大的项目有一些powershell代码,旨在保持每个项目之间的版本号相同。当我构建它时,我禁用了我的Package元素,我没有注意到Compressed属性已被删除。将其添加回可以纠正问题。谢谢