/build/static/layout/Breadcrumb_cap_w.png

Files being deleted on Upgrade

Hi--
I have an application we created with a file that is now being placed by the executable on first launch and not the installer. I need to remove the file from the installer so the executable won't see it, but not from the destination computer. This will allow the users' to keep thier edited version of this file, while new users (first installers) will get the updated version. No matter what I try, the file is deleted from the destination computer. The file's componant is marked "Keep Installed on Uninstall", and "Never Overwrite if KeyFile exists."

I use Wise Installation Studio v7. Any help would be graetly appreciated.

0 Comments   [ + ] Show comments

Answers (5)

Posted by: Superfreak3 13 years ago
2nd Degree Black Belt
0
I'm a bit uncertain as to what you are actually trying to do. You install an .exe. When launched, it creates a file that you want to keep? Since it is not part of the actual installation, it should be left behind on uninstall.

This is confusing...

I need to remove the file from the installer so the executable won't see it, but not from the destination computer.

If you can clarify a bit I might be able to help as I just moved away from Wise Installation Studio v7.
Posted by: t_claydon 13 years ago
Senior Yellow Belt
0
Say the file is called MyConfig.ini. What you do is rename it to MyConfig.Tmp and have the MSI lay it down in the relevent directory. You then run a custom action that runs on install that checks to see if MyConfig.ini exists in the directory and if it doesn't it copys MyConfig.tmp to MyConfig.ini.
Posted by: kpm30519 13 years ago
Yellow Belt
0
Superfreak3
To clarify, the old version's installer placed the file in the My Docs folder. The user then edits the file. In the new version, this file should no longer be placed by the installer, but by the exe. If the installer places it, the edited files may get overwritten, and the exe won't place it, because the installer did, so no changes to the file will be sent to the new users. Hope that helps (it's still early here...)
Posted by: pjgeutjens 13 years ago
Red Belt
0
My Docs folder
No matter what I try, the file is deleted from the destination computer


What is the value for the ALLUSERS property in this package? Also, are you installing using a distribution system? If I'm not mistaken, files that go into the users' profiles do not get placed by the installer during initial install if ALLUSERS is set to 1, this is the realm of self-healing or ActiveSetups. So it's kind of strange to me that these files get deleted on update or uninstall, since this is not default Windows Installer behaviour.

Maybe there's some custom action or ActiveSetup/Runonce that does the cleanup of these files, and that gets put in place upon uninstall of the package?

If ALLUSERS is set to 2, and you're using RemoveExistingProducts to do the upgrade, can you tell me where the RemoveExistingProducts is scheduled in the Execute Sequence?

PJ
Posted by: mazessj 13 years ago
Blue Belt
0
Did the original version of the installer not have the "Leave installed on uninstall" (AKA "permanent") and "Never overwrite if key path exists" attributes set on this particular file's component? If the package was already installed on the user's machine before you changed these attributes, it's too late. You can't change an installation that's already been installed on a user's machine. However, you can try patching (ugly) to apply the changes to the component.

If you are looking to fix an installation that you did wrong originally, and you're not looking to patch, you'll likely have to build a new installer that compensates for this mistake and backs up/restores the file on upgrade. Alternatively, you can write a wrapper script for your package that handles the backup/restore operations outside of the MSI.
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ