Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

wix installer failing Error code 2819

Tags:

wix

I am attempting to build an installer with wix.

It compiles and runs. Unfortunately when I run it, I accept the license agreement and hit next, then it explodes.

Error

"The installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is 2819."

Here is the code I am using

Code

<?xml version="1.0" encoding="UTF-8"?> <Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">   <Product Id="*" Name="rd Installer" Language="1033" Version="1.0.0.0" Manufacturer="hs" UpgradeCode="upgradeCode">     <Package InstallerVersion="200" Compressed="yes" InstallScope="perMachine" />     <MajorUpgrade DowngradeErrorMessage="A newer version of [ProductName] is already installed." />     <MediaTemplate EmbedCab="yes" />          <Directory Id="TARGETDIR" Name="SourceDir">       <Directory Id="ProgramFilesFolder">                 <Directory Id="INSTALLFOLDER" Name="rd">           <Directory Id="BINFOLDER" Name="Bin"/>           <Directory Id="IMAGEFOLDER" Name="Image"/>         </Directory>       </Directory>     </Directory>   <DirectoryRef Id="INSTALLFOLDER">        <Component Id="CMP_rd1" Guid="guid">     <File Id="rd1"          Name="r.d"          Source="D:\dir\file.txt"          KeyPath="yes">     </File>   </Component>   <Component Id="CMP_rd2" Guid="guid">     <File Id="rd2"          Name="r.d"          Source="D:\dir\file.txt"          KeyPath="yes">     </File>   </Component> </DirectoryRef> <Feature Id="DefaultFeature" Level="1">   <ComponentRef Id="CMP_rd1"/>   <ComponentRef Id="CMP_rd2"/> </Feature>      <UI Id="UI_ReportDasboard">       <UIRef Id="WixUI_InstallDir"/>     </UI>        </Product>   </Wix> 

I've looked at a number of examples and I cant seem to understand what's wrong. My code looks very close to the examples I've seen. Am I missing something?

like image 629
Anthony Russell Avatar asked Jun 26 '14 18:06

Anthony Russell


2 Answers

You need to set the WIXUI_INSTALLDIR property.

<Property Id="WIXUI_INSTALLDIR" Value="INSTALLFOLDER" /> 

More info here

like image 100
Rick Bowerman Avatar answered Sep 21 '22 08:09

Rick Bowerman


I was receiving the error 2819 having

   <Control Id="SelectWebSiteList" Type="ListBox" X="20" Y="75" Width="200" Height="150" Sorted="yes" Property="WEBSITE" /> 

without

    Property="WEBSITE" 
like image 32
michalh Avatar answered Sep 17 '22 08:09

michalh