I am having trouble getting my installation to work correctly. In my
installation, the user needs to select 3 paths, the Program Installation
folder, the Local data folder, and the Server data folder. The Local and
Server data folders can be shared, or separate folders depending on the
user. I have got the install to allow to select all three folders, and the
properties are getting updated, but for some reason, it is not updating the
sub-folders of my Server data folder. However, both the Program install and
the Local data folders are updating correctly, and I am totally stumped as
to what is happening. If anyone can help I would sincerely appreciate it.
I am including copies of the WXS files as well as the relevant portion of
the log file to help to try to determine what the problem is.
I am assuming that the user is performing a full UI install, at the present
point in time. I may allow for Minimal UI and Administrative installs
later, but I need to get it working with the Full UI currently. I removed
all GUIDs from the files and inserted YOUR_GUID_HERE instead. I also
anonymized the folder names. I have attached the section of the install log
showing where the local data folder path was updated, but the server data
sub-folders were not, at the end of the message.
WIX_UICustom:
Wix xmlns=http://schemas.microsoft.com/wix/2006/wi;
Fragment
UIRef Id=WixUI_Common /
UI Id=WixUI_Custom
TextStyle Id=WixUI_Font_Normal FaceName=Tahoma Size=8 /
TextStyle Id=WixUI_Font_Bigger FaceName=Tahoma Size=12 /
TextStyle Id=WixUI_Font_Title FaceName=Tahoma Size=9 Bold=yes
/
Property Id=DefaultUIFont Value=WixUI_Font_Normal /
DialogRef Id=ErrorDlg /
DialogRef Id=FatalError /
DialogRef Id=FilesInUse /
DialogRef Id=MsiRMFilesInUse /
DialogRef Id=PrepareDlg /
DialogRef Id=ProgressDlg /
DialogRef Id=ResumeDlg /
DialogRef Id=UserExit /
Publish Dialog=ExitDialog Control=Finish Event=EndDialog
Value=Return Order=9991/Publish
Publish Dialog=WelcomeDlg Control=Next
Property=_InstallDirBrowserProperty Value=PROGRAMFOLDER
Order=11/Publish
Publish Dialog=WelcomeDlg Control=Next
Property=_LocalJSDDirBrowserProperty Value=DATAFOLDER
Order=11/Publish
Publish Dialog=WelcomeDlg Control=Next
Property=_ServerJSDDirBrowserProperty Value=SERVERDATAFOLDER
Order=11/Publish
Publish Dialog=WelcomeDlg Control=Next Event=NewDialog
Value=MyInstallDirDlg Order=2NOT Installed AND NOT PATCH/Publish
Publish Dialog=WelcomeDlg Control=Next Event=NewDialog
Value=VerifyReadyDlg Order=2Installed AND PATCH/Publish
Publish Dialog=MyInstallDirDlg Control=Back Event=NewDialog
Value=WelcomeDlg1/Publish
Publish Dialog=MyInstallDirDlg Control=Next Event=NewDialog
Value=VerifyReadyDlg1/Publish
Publish Dialog=VerifyReadyDlg Control=Back Event=NewDialog
Value=MyInstallDirDlg Order=1WixUI_InstallMode =
InstallComplete/Publish
Publish Dialog=VerifyReadyDlg Control=Back Event=NewDialog
Value=MaintenanceTypeDlg Order=2WixUI_InstallMode = Repair OR
WixUI_InstallMode = Remove/Publish
Publish Dialog=VerifyReadyDlg Control=Back Event=NewDialog
Value=WelcomeDlg Order=1WixUI_InstallMode = Update/Publish
Publish Dialog=MaintenanceWelcomeDlg Control=Next
Event=NewDialog Value=MaintenanceTypeDlg1/Publish
Publish Dialog=MaintenanceTypeDlg Control=RepairButton
Event=NewDialog Value=VerifyReadyDlg1/Publish
Publish Dialog=MaintenanceTypeDlg Control=RemoveButton
Event=NewDialog Value=VerifyReadyDlg1/Publish
Publish Dialog=MaintenanceTypeDlg Control=Back Event=NewDialog
Value=MaintenanceWelcomeDlg1/Publish
/UI
/Fragment
/Wix
The relevant portion of my Directories.wxs:
?xml version=1.0 encoding=UTF-8?
Wix xmlns=http://schemas.microsoft.com/wix/2006/wi;
Fragment
Directory Id=TARGETDIR Name=SourceDir
Directory Id=DATAFOLDER Name=My_Data
Component Id=DataFolderComponent Guid=YOUR_GUID_HERE
KeyPath=yes NeverOverwrite=no Permanent=no Transitive=no Win64=no
Location=either
CreateFolder/
/Component
Component Id=DataFolderRegistry Guid=YOUR_GUID_HERE
RegistryValue Root=HKLM Key=SOFTWARE\My Software
Name=Data_Location Action=write Type=string Value=[DATAFOLDER]/
/Component
Directory Id=LOGSFOLDER Name=Logs
Component Id=LogsFolderComponent Guid=YOUR_GUID_HERE
SharedDllRefCount=no KeyPath=yes NeverOverwrite=no Permanent=no
Transitive=no Win64=no Location=either
CreateFolder/
/Component
/Directory
/Directory
Directory Id=SERVERDATAFOLDER Name=My_Data
Component Id=ServerDataFolderRegistry Guid=YOUR_GUID_HERE
RegistryValue Root=HKLM Key=SOFTWARE\My Software
Name=Server_Data_Location KeyPath=yes Action=write Type=string
Value=[SERVERDATAFOLDER] /
/Component