Copy Files and build Dest Path from Sourcefile Path

hi there...

need a solution for this problem...

i need to copy files from the filecollection wich are real located in {folder}{folder1}{folder2}{folder3}{folder4}\filename.ext
to a new folder. the copied files have to be placed in {destpath} and then {folder3}{folder4}\ from the original sourcefile location.

any idea how to realize this? working since hours on it with no success...
thanx for help

I think this command will do what you want.

Warning: It'll probably do something strange, or just fail, on files which don't have at least two parent directories.

@nofilenamequoting Copy "{filepath$}" CREATEFOLDER "{filepath$|..\..|nopath}{filepath$|..|nopath}"


thanks a lot...it works like a charme...