Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1757
  • Last Modified:

Copy files from subfolders to one folder with no subfolders

Hello,

I need to create a batch file to copy files from a folder with subfolders and place them in a destination folder without the entire tree struction.

I have tried XCOPY but it copies the entire structure.  I didn't see any of the swtiches to remove the subfolders.

Thanks so much!!!
0
NancyCPS
Asked:
NancyCPS
1 Solution
 
John-Charles-HerzbergCommented:
0
 
Aaron TomoskyTechnology ConsultantCommented:
Robocopy.
0
 
subhashchyCommented:

for /f %a in ('dir /s /b') do move %a c:\test\

try this..

Note that if duplicates found it will not overrite

0
 
NancyCPSAuthor Commented:
Thanks soooooooooo much.
0

Featured Post

Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

Tackle projects and never again get stuck behind a technical roadblock.
Join Now