Home | Reviews | GUIpedia | Forum | Fun500


JasonXCOPY problems
XCOPY doesn't seem to copy long file names in DOS 7.1, anyone know an alternative or a solution?
2010-07-161:59 AM

BrandonRe:XCOPY problems
Well the obvious solution would be to not use long file names.
2010-07-169:09 AM

JasonRe:XCOPY problems
LFN is a special feature, i wouldnt give it up because xcopy wasnt written properly. i thought you didnt want to talk to me
2010-07-1610:33 AM

ToddRe:XCOPY problems
Copy this into a batch file named "tcopy.bat" and see if it works (requires LFNDOS tools):   lcopy %1 %2
for /f %%f IN ('ldir /ad /b %1') do (
  if not exist %2\%%f lmd %2\%%f
  tcopy.bat %%f\%1 %2\%%f\
)   Should work like this: tcopy c:\dir1\*.* c:\dir2\
2010-07-161:03 PM

ToddRe:XCOPY problems
Thanks! Yes it should copy sub-directories.
2010-07-161:29 PM

ToddRe:XCOPY problems
No I mean "lcopy" which works to copy long-filenames. http://lfntools.sourceforge.net/ If you don't want to use LFN Tools, then just remove the "l" before "lcopy", "ldir", and "lmd".
2010-07-161:52 PM

JasonRe:XCOPY problems
i have a few problems.  after copying the screen fills up with \%f\\%f\\ ..... how would you copy subdirs?
2010-07-161:53 PM

JasonRe:XCOPY problems
i mean it doesnt copy subdirs
2010-07-162:15 PM

ToddRe:XCOPY problems
The algorithm is pretty simple. Create a function to copy all files then list directories. For each directory, call the function again for that directory (recursion).
2010-07-162:22 PM

JasonRe:XCOPY problems
i dont know if you tested but on this ldir /ad i imagine that the /ad means directories, in this file it means display hidden files
2010-07-162:30 PM

ToddRe:XCOPY problems
I assumed they were similar but I wrote the batch file on XP so I can't run those DOS programs anyway.
2010-07-162:32 PM

JasonRe:XCOPY problems
hmm, i guess i gotta go on googling?
2010-07-162:33 PM

ToddRe:XCOPY problems
Or better yet, write a DOS program to do it. It shouldn't be too hard.
2010-07-162:43 PM

JasonRe:XCOPY problems SOLVED
after many minutes of googling, i found a program called XCLONE :D .... D: it doesnt support lfn   btw i was wondering if it copied the whole tree or just the folders in the folder?   apart from that there is nothing for dos that will work, i have looked EVERYWHERE! :\ still gotta keep looking though EDIT: i found out that xcopy will copy lfns in windows flawlessly, whats the difference between dos? ----------------------------------------------------------------------------------------- i must have had an old version theres a /S (subdir) thingy
2010-07-162:45 PM

Other


2021 Brandon Cornell