Copy File immediately prior to previous version uninstall

Got a problem you cannot solve? Try here.
Post Reply
tmenninger
Posts: 2
Joined: Mon Nov 09, 2009 10:10 am

Copy File immediately prior to previous version uninstall

Post by tmenninger »

I am looking for more options for this. I have a previous installed version i am trying to uninstall. I have it detecting the previous version. The old installer deletes the entire install directory but i need to save off a config file from the old version and move it back into place after the uninstall of the old version.

If i understand this correctly all the commands to do things in the installer do not happen immediately but rather get executed when Apply Install command executes. All I want to do is copy a file off and uninstall the previous version. Both copy file and read text from file do nothing at the time of uninstall.

I have tried calling Apply Change right after the file copy and before the uninstall however there seems to be an issue with the old installer since if i do this i get an error message. Something about it cant find the old installer file "A network error occurred while attempting to read from the file: C:\\DOCUME~1\\ADMINI~1\\LOCALS~1\\Temp\\1\\mia1\\MyInstaller.msi"

Is there anything i can do to copy the file immiedately or address the error?
neillans
Posts: 536
Joined: Sat Nov 04, 2006 6:21 am
Location: Scottish Borders, UK

Post by neillans »

How are you copying the old config out? The best way to do this is using Call DLL Function plugin to call CopyFile, and backup the configuration. carry out the installation, then Call DLL Function again to copy the file back -- after apply install.
Andy Neillans
tmenninger
Posts: 2
Joined: Mon Nov 09, 2009 10:10 am

Post by tmenninger »

Thank you very much. Worked like a champ!
Post Reply