Page 1 of 1

renaming via Copy Local Files

Posted: Mon Oct 15, 2012 8:12 am
by christ23
Hi there,

i got a stupid problem which i cannot solve. But i think the solution is easier as i think ...

- i copy some files via "unzip 7z" to local temp (C:\Temp\xyz\)
- i then want to copy a file out of C:\Temp\xyz to another local target, lets say it is P:\xxx- BUT during doing this, i want the file to be renamed

The Copy/Move local files command windows seems to me as this can be done.

The source file in my example is called A_300.exe, and the target name should be A.exe (without the version number)

This is my msiCode:

Code: Select all

Set Variable NATIVE_ENGINE to TRUE
Copy Local Files $sourcefolder$\A_*.exe to $targetfolder$\A.exe
(Apply Install (get result into variable success))
The file gets copied, BUT it still has the name "A_300.exe". Any ideas what i am doing wrong?

Re: renaming via Copy Local Files

Posted: Mon Oct 15, 2012 11:29 am
by FrancescoT
Dear Christ23,

I have personally done the same, probably not using your same source & destination folders ... and the file has be renamed correctly.

With my code I just executed the Copy Command without having Apply Install as you have.
Are you sure that the files is unintentionally replaced by Apply Install in some ways?

Regards