I’d like to move some files from where the directory is installed to a second location with a MSI.
I created a component that refers to the second directory and added there the CopyFile element:
<CopyFile Id="copy" DestinationProperty="AUSTORAGE" SourceProperty="PFSTORAGE" SourceName="*.*" Delete="yes" />
It doesn’t seem to copy anything but after taking a look at the logs its seems like the component that copy the files is executed before the files are copied to the first directory during the installation.
Is there any way to control the secuence of the components? Or any better aproach to copy the files (all the files in a directory)?
Just move your CopyFile element under the File element (the file you’d like to copy after it is installed), and it will appear in the right order. The point here is the DuplicateFile table functionality (the one Ciprian mentions here) is also included into the CopyFile element logic. See CopyFile element help for more details.