Home » Questions » Computers [ Ask a new question ]

Batch file to copy folder structure

Batch file to copy folder structure

I want write a batch file that can copy a folder structure. This batch file would copy all folders in the source directory to the destination directory - the files themselves would not be copied.

Asked by: Guest | Views: 229
Total answers/comments: 3
Guest [Entry]

"Try:

XCopy ""src"" ""dest"" /T

Just make sure it's not cyclical.

To include empty directories, add /E:

XCopy ""src"" ""dest"" /T /E"
Guest [Entry]

"not a batch file but Total Commander can do this (with a little trick):

copy a directory and use the 'Only files of this type' option. enter *.nonsense (or any other non-existent file extension) in this field.

now Total Commander will create the entire directory structure of the source folder at the destination without copying any files."
Guest [Entry]

Check 47 folders app , can create & copy folders structures in visual way..