1
votes

I have been using WiX to create an installer for my project. It's fairly simple, just drop some files in a number of spots and run a VBScript to generate one last file.

After some difficulties with the VBS I got it installing, but when I uninstall the package disappears out of Control Panel but the files that were installed are still there.

I have install and uninstall logs, and also have posted the WiX source file. Links are below.

Any help is much appreciated!

install log

WiX source

uninstall log

Note that this is being installed on Server 2003.

I know it's full of drive letters and full paths, and that isn't best practice, but that's where the files need to go. This doesn't go to a variety of computer types and configurations; there are over ten thousand of these systems in our retail locations and they're all identical.

1
I think you mixed up the links for your log files, but is the problem just that the files created by your vb script are not deleted, or also the wix Components? You seem to be running the script custom action on both install and uninstall. - Dave Andersen
I may well have messed up the links, sorry about that. The problem is that all installed files were not being removed. I didn't expect it to get the one that I create out of VBS. I saw that the script was running on install and uninstall but figured I'd work on that next. It's a small file that gets created and I'm not sure I actually want to delete it anyway. - Walt

1 Answers

0
votes

I was running the Custom Action at the wrong time, so it ran too late in the uninstall to define where the C Drive is.

I changed from what is in the WiX above to:

<CustomAction Id="CA_SetCDrive" Directory="C_DRIVE" Value="c:\" />

<InstallExecuteSequence>
     <Custom Action="CA_SetCDrive" After="CostFinalize" />
</InstallExecuteSequence>

<Directory Id="TARGETDIR" Name="SourceDir">
     <Directory Id="C_DRIVE" Name="CDrive" />
</Directory>

and now it works fine.