cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Not applicable

Copy file before install begins and then after

Need to find out if anyone has a script to search for a file copy it to a temp directory before install begins. Then copy it back over writting the current file after install completes. Any replies are greatly appreciated
Labels (1)
0 Kudos

(3) Replies
RobertDickau
Flexera Alumni

What kind of project is this---InstallScript or MSI? With InstallScript, for example, you could find the file with FindAllFiles and copy it somewhere with XCopyFile, and later copy back using the same function... (That's assuming it's not an option just to avoid overwriting the file in the first place.)
0 Kudos
Not applicable

It is a Basic MSI Project
0 Kudos
RobertDickau
Flexera Alumni

Before going too far down that road, those types of custom actions have repercussions on repair, self-repair, upgrades, and so on. Is it an option just to avoid installing/overwriting that file if it already exists?
0 Kudos