How do I get around long file directory names in DOS using xcopy?

Posted by RockFan under Software
peter b asked:

My source is — G:\MUSIC
My destination is C:\MUSIC

My attempted command line was:
xcopy G:\MUSIC C:\MUSIC /s /e /h

It started to copy fine but then it came across the following file in the following subdirectory
G:\MUSIC\70’s\Janis Joplin 10 Cd Essential Collection
It the said = Unable to create directory.

What xcopy line will copy everything regardless of how long a directory – subdirectory – file name is or regardless what charachters are in it.

Any ideas? thanks

Share this site:
  • Digg
  • del.icio.us
  • Facebook
  • Reddit
  • StumbleUpon
  • YahooMyWeb
  • Google Bookmarks
  • Yahoo! Buzz
  • TwitThis
  • Live
  • LinkedIn
  • MySpace
  • email
  • MisterWong
One Response to “How do I get around long file directory names in DOS using xcopy?”
  1. mdigitale Says:

    DOS doesn’t have support for long file names.

    If you’re using the emulated DOS (via cmd) in Windows, there is limited support if the tool supports it — I don’t think xcopy does.

    Your best solution: Write (or download) an xcopy application that does support long file names. Xcopy is about the most simple program in the world so it shouldn’t be hard.

Leave a Reply