Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

xcopy command

  • 25-07-2009 03:20AM
    #1
    Registered Users, Registered Users 2 Posts: 8,489 ✭✭✭


    I'm using XP Pro & trying to run the xcopy command but can't get it to work.

    I'm trying to use it to copy a DVD in (Drive D:\) to a Pen Drive (Drive H:\)

    I'm also using the /e & /f switches

    This is how I'm typing it

    xcopy d:\ h:\ /e /f

    Everytime I run it from the command prompt I get the following message,

    Unable to create directory – H:\

    What am I doing wrong?


    -

    "Everybody is a genius. But if you judge a fish by its ability to climb a tree, it will live its whole life believing that it is stupid."



Comments

  • Registered Users, Registered Users 2, Paid Member Posts: 31,128 ✭✭✭✭Ghost Train


    maybe try adding wild card

    xcopy d:\ h:\* /e /f

    xcopy d:\ h:\*.* /e /f


  • Registered Users, Registered Users 2 Posts: 8,489 ✭✭✭Gadgetman496


    maybe try adding wild card

    xcopy d:\ h:\* /e /f

    xcopy d:\ h:\*.* /e /f


    No joy there either but thanks for the reply :)

    I even tried it straight without the switches but it still returns

    Unable to create directory – H:\
    0 file(s) copied

    -

    Edit:

    I've tried this on 3 different machines now & the result is the same.

    The only thing in common with all machines is that they are all XP Pro SP3

    I wonder if SP3 is causing it?

    -

    "Everybody is a genius. But if you judge a fish by its ability to climb a tree, it will live its whole life believing that it is stupid."



  • Registered Users, Registered Users 2 Posts: 8,489 ✭✭✭Gadgetman496


    I decided as it was not able to create the directory on the pen drive (Drive H:) that I would try the xcopy command but this time copying from the DVD drive (Drive D:\) to a folder on the PC and that worked no problem.

    Tried it once more with a different pen drive & again it failed.

    Why doesn't xcopy seem to want to write to a pen drive? :confused:

    -

    "Everybody is a genius. But if you judge a fish by its ability to climb a tree, it will live its whole life believing that it is stupid."



  • Registered Users, Registered Users 2, Paid Member Posts: 31,128 ✭✭✭✭Ghost Train


    weird... maybe disabling fast removal of the key, under the properties of the drive... really not sure though


  • Registered Users, Registered Users 2 Posts: 8,489 ✭✭✭Gadgetman496


    weird... maybe disabling fast removal of the key, under the properties of the drive... really not sure though

    I had tried that too but no lick.

    I'm going to change the drive letter assigned to the pen drive & see?

    I know it sounds crazy but could xcopy have an issue with a drive assigned a drive letter as high a H:\?

    I'm running out of ideas now myself :(

    -

    "Everybody is a genius. But if you judge a fish by its ability to climb a tree, it will live its whole life believing that it is stupid."



  • Advertisement
  • Registered Users, Registered Users 2 Posts: 8,489 ✭✭✭Gadgetman496


    Solved:

    Ghost Train,

    You were so on the right track with your mention of using the wild card * ;)

    Thanks for your efforts ;)

    This is why I was unable to carry out the xcopy command to a Pen Drive.



    Using xcopy to copy the contents of a CD/DVD to a Pen Drive:


    It is wise to give the full path when using xcopy as DOS sometimes gets confused when you try to xcopy to an external drive such as a Pen Drive.

    If you want to xcopy from a DVD disc in your DVD drive to a drive on your hard disc this xcopy command will work fine. xcopy d: c: /e /f (assuming that D:\ is your DVD drive & C: is your hard drive).

    However if you try to do it to a pen drive (assuming that D:\ is your DVD drive & H:\ is your Pen Drive) using xcopy d: h: e/ f/
    it will give the following error

    Unable to create directory – h:
    0 file(s) copied

    However, if you use the full path like the line below it will work fine.

    xcopy d:\*.* h:\*.* /e /f


    Solution:

    Thanks again Ghost Train for your input.

    -

    "Everybody is a genius. But if you judge a fish by its ability to climb a tree, it will live its whole life believing that it is stupid."



Advertisement