Batch file to copy files

Closed
Esmm3 - Feb 3, 2010 at 01:11 PM
rizvisa1
Posts
4479
Registration date
Thursday January 28, 2010
Status
Contributor
Last seen
May 5, 2022
- Feb 3, 2010 at 01:45 PM
Hello,

I am doing a migration and I need a batch file or script that will allow me to copy certain files and folders from the useres current pc to the network and then to the new PC in the same location.

So for isntance I need to copy the users signature for outlook.

I tried using robocopy

robocopy "%userprofile%\Application Data\Microsoft\Signatures" "H:\New Directory" /V /NP /R:10 /W:30

now that only copies the files in the signature folder and not the folder itself.

So basically what i want it to do is to copy that folder to the server and then copy it to the new PC in the same location.

any help on this would be great as I am totally lost...

Thanks

3 replies

rizvisa1
Posts
4479
Registration date
Thursday January 28, 2010
Status
Contributor
Last seen
May 5, 2022
769
Feb 3, 2010 at 01:31 PM
add /s /e options

see the help of robocopy by typing robocopy /? to see what options do what
0
I added those switches but it still only copies the contents of the signature folder and not the folder itself.
0
rizvisa1
Posts
4479
Registration date
Thursday January 28, 2010
Status
Contributor
Last seen
May 5, 2022
769
Feb 3, 2010 at 01:45 PM
which folder ? The signature folder or you are talking about subfolders in signature folder. If you are talking about signature folder, then you need to one level up and then copy signature.
0