TOTAL noob xcopy question ...


  1. Posts : 18
    windows / Linux - Depending on mood
       #1

    TOTAL noob xcopy question ...


    Guys I am sorry to have to ask this but I can't for the life of me recall xcopy commands lol ...

    Using the batch file:-
    Code:
    @echo off
    cls
    N:
    cd \
    mkdir 1047483660
    cd 1047483660
    xcopy "\\myserver\myshare\Folder1" /c /f /s /e >> c:\xcopy.log
    Although the files copy OK (here's xcopy.log)
    Code:
    \\myserver\myshare\Folder1\File1.avi -> N:\1047483660\File1.avi
    \\myserver\myshare\Folder1\File2.avi -> N:\1047483660\File2.avi
    \\myserver\myshare\Folder1\File3.avi -> N:\1047483660\File3.avi
    I want it to make the same folder structure on the destination path instead of dumping all the files into the 'root'

    (ie, so xcopy.log reads)
    Code:
    \\myserver\myshare\Folder1\File1.avi -> N:\1047483660\Folder1\File1.avi
    \\myserver\myshare\Folder1\File2.avi -> N:\1047483660\Folder1\File2.avi
    \\myserver\myshare\Folder1\File3.avi -> N:\1047483660\Folder1\File3.avi
    
    I hope that makes sense, sorry, it's been a Loooooooooooooooooooong day lol!
    Thank you for any assistance you can offer me!!
    Last edited by badgerfruit; 03 May 2011 at 14:47. Reason: gramtical errors
      My Computer


  2. whs
    Posts : 26,210
    Vista, Windows7, Mint Mate, Zorin, Windows 8
       #2

    Did you try xcopy /? in cmd. That gives you the parameters.
      My Computer


  3. Posts : 8,608
    Windows 7 Ultimate 32bit SP1
       #3

    Heres a list Xcopy
      My Computer


  4. Posts : 18
    windows / Linux - Depending on mood
    Thread Starter
       #4

    hello, thank you for the prompt replies but I did read technet before making the batch file and I thought that I had hit the right combination, clearly not
      My Computer


  5. Posts : 16,161
    7 X64
       #5

    Try

    md 1047483660\Folder1

    cd 1047483660\Folder1

    Or, if you have several, e.g. Folder1, Folder2, etc you want to copy you can go up a level

    md 1047483660

    cd 1047483660

    xcopy "\\myserver\myshare" /cefs
      My Computers


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 12:03.
Find Us