Ideally I prefer the simplicity of a messagebox over a wizard for uninstalling, since a yes/no answer is all that is needed, but I think I might just move the data directory to the recycle bin and not bother the user with a question at all, since this still gives them the ability to restore it if need be.
I am of the opinion that treating a user's personal information (i.e. data that cannot simply be "reinstalled") in the same manner as the application itself can be dangerous. While it is true that uninstalling a program generally also means remove all user data along with it, it's also possible that the user might not realize that and decide to manually reinstall the application by uninstalling and reinstalling it. It would be a shame if at the end of this operation they realized all their data was gone (my program stores all of the user's data in a database, so we are talking some potentially important stuff here). At least if it's in the recycle bin, all they have to do is click the directory and choose "Restore". Worst case (not counting accidentally emptying the recycle bin :P) is that they panic, email me, and I tell them to check their recycle bin, and they let out a big WHEW! No big deal. However if that data really IS gone, that IS a big deal, and I want to avoid that at all costs. So that said, do I really have to worry about patching/upgrading/rolling back? My program is simple (and small) enough that I have no plans to ever patch pieces of an install. The major upgrade suits me just fine for now. As for rolling back, if some error occurs during uninstall, the worst case scenario is that the custom action executes and the user's data ends up in the recycle bin, however I don't even think this will happen because the custom action is scheduled at the very end, after InstallFinalize, which means that if an error occurs, the rollback will take place before the custom action is even executed. Is this not correct? Thanks for the tips and pointers. I've run through some tests and it appears to be working (executing the CA on full uninstall but not on an upgrade) so I thank you all for your help! Logan Rob Mensching-2 wrote: > > 1. Windows Installer can remove files based off a property. So you can > prompt and set a property appropriately to remove the files or not. > > 2. I don't think files go into the recycle bin. So you may have to have > a CustomAction for that. Too bad, since it means you'll have to think > through all the install/uninstall/patching/upgrade/rollback for all that > semantics. > > I've never heard someone say, "Oh, it'll be easier to write a CustomAction > than use the built in Windows Installer functionality after shipping a > CustomAction." <smile/> > ----- A. Logan Murray http://pihole.org/ -- View this message in context: http://n2.nabble.com/Run-CA-on-uninstall%2C-but-not-when-updating-%28RemovePreviousVersions%29-tp1372539p1373156.html Sent from the wix-users mailing list archive at Nabble.com. ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users