I tried placing the directory reference in various places. Then I got rid that <directory entry entirely and I tried setting the property directly, I've tried the following:
<Property Id="ZIPDIRECTORY" Value="." />
<Property Id="ZIPDIRECTORY" />
<Property Id="ZIPDIRECTORY">C:\</property>
<Property Id="ZIPDIRECTORY" Value="C:\" />
<Property Id="ZIPDIRECTORY" Value="APPLICATIONROOTDIRECTORY" />
I'm not having very much luck finding an answer via Google. The errors I've gotten include:
Error 2343: Specified path is empty.
Error 2819: Control Folder on dialog InstallDlg needs a property linked to it
Error 2343: Specified path is empty.
There may have been others. The previous value is sent to my custom action via Session.CustomActionData
Thanks for your help. The only thing I edited out was my list of files to include.
Code: Select all
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi" xmlns:util="http://schemas.microsoft.com/wix/UtilExtension">
<Product Id="55a8b9ce-803b-4455-b600-aff9cbc70709"
Name="Something"
Language="1033"
Version="!(bind.FileVersion.Something.exe)"
Manufacturer="EMSI"
UpgradeCode="f339527d-68d6-47f0-8ab7-fd25a38d23ad">
<Package InstallerVersion="200" Compressed="yes" InstallScope="perMachine" />
<Binary Id="Something.Install.CustomAction.CA.dll" SourceFile="..\Something.Install.CustomAction\obj\$(var.Platform)\$(var.Configuration)\Something.Install.CustomAction.CA.dll" />
<Media Id="1" Cabinet="media1.cab" EmbedCab="yes" />
<Directory Id="TARGETDIR" Name="SourceDir">
<Directory Id="ProgramFilesFolder">
<Directory Id="EMSIFolder" Name="EMSI">
<Directory Id="APPLICATIONROOTDIRECTORY" Name="Something">
<Component Id="APPLICATIONROOTDIRECTORY" Guid="{a6cf2817-7027-4ac4-bc51-69253582599a}">
<CreateFolder />
<RemoveFile Id="PurgeAppFolder" Name="*.*" On="uninstall" />
</Component>
</Directory>
</Directory>
</Directory>
</Directory>
<Property Id="WIXUI_INSTALLDIR" Value="APPLICATIONROOTDIRECTORY" />
<Property Id="ZIPDIRECTORY" Value="C:\" />
<UIRef Id="WixUI_InstallDir" />
<DirectoryRef Id="APPLICATIONROOTDIRECTORY">
</DirectoryRef>
<Feature Id="MainApplication" Title="Main Application" Level="1">
</Feature>
<CustomAction Id="SetupCustomActionData" Property="BuildConfigurations" Value="ENVIRONMENTSELECTION=[ENVIRONMENTSELECTION];APPLICATIONROOTDIRECTORY=[APPLICATIONROOTDIRECTORY];ZIPDIRECTORY=[ZIPDIRECTORY]" />
<CustomAction Id="BuildConfigurations"
BinaryKey="Something.Install.CustomAction.CA.dll"
DllEntry="BuildConfigurations"
Execute="deferred"
Return="check" />
<InstallExecuteSequence>
<Custom Action="SetupCustomActionData" After="InstallFiles">Not Installed</Custom>
<Custom Action="BuildConfigurations" After="SetupCustomActionData">Not Installed</Custom>
</InstallExecuteSequence>
<UI>
<TextStyle Id="DefaultFont" FaceName="Tahoma" Size="8" />
<Dialog Id="InstallDlg" Width="370" Height="270" Title="[ProductName] [Setup]" NoMinimize="yes">
<Control Id="Title" Type="Text" X="5" Y="20" Width="360" Height="25" Transparent="yes" NoPrefix="yes">
<Text>{\DlgFont8}Choose which environment the application is being installed in:</Text>
</Control>
<Control Id="Buttons" Type="RadioButtonGroup" X="30" Y="50" Width="104" Height="56" Property="ENVIRONMENTSELECTION" />
<Control Id="ZipPrompt" Type="Text" X="5" Y="115" Width="360" Height="25" Transparent="yes" NoPrefix="yes">
<Text>{\DlgFont8}Enter destination path for downloaded zip:</Text>
</Control>
<Control Type="PathEdit" Id="Folder" Width="280" Height="15" X="11" Y="135" Property="ZIPDIRECTORY" Indirect="yes" />
<Control Type="PushButton" Id="Browse" Width="56" Height="17" X="296" Y="131" Text="Browse...">
<Publish Property="_BrowseProperty" Value="ZIPDIRECTORY" Order="1">1</Publish>
<Publish Event="SpawnDialog" Value="BrowseDlg" Order="2">1</Publish>
</Control>
<Control Type="Line" Id="line" Width="362" Height="2" X="4" Y="229" />
<Control Id="Install" Type="PushButton" X="304" Y="243" Width="56" Height="17" Default="yes" Text="Next">
<Publish Property="ENVIRONMENTSELECTION" Value="[ENVIRONMENTSELECTION]" />
<Publish Property="ZIPDIRECTORY" Value="[ZIPDIRECTORY]" />
<Publish Event="EndDialog" Value="Return" />
</Control>
</Dialog>
<RadioButtonGroup Property="ENVIRONMENTSELECTION">
<RadioButton Text="Dev" Value="1" X="5" Y="0" Width="95" Height="13" />
<RadioButton Text="Developer" Value="2" X="5" Y="14" Width="95" Height="13" />
<RadioButton Text="Test" Value="3" X="5" Y="28" Width="95" Height="13" />
<RadioButton Text="Production" Value="4" X="5" Y="41" Width="95" Height="13" />
</RadioButtonGroup>
<TextStyle Id="DlgFont8" FaceName="Tahoma" Size="12" />
<InstallUISequence>
<Show Dialog="InstallDlg" After="CostFinalize" />
</InstallUISequence>
<Property Id="ENVIRONMENTSELECTION">3</Property>
</UI>
</Product>
</Wix>
FOLLOW US
Get the latest news in Application Packaging