Solved

Copy files from subfolders to one folder with no subfolders

Posted on 2011-03-03
4
1,707 Views
Last Modified: 2012-08-14
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
Comment
Question by:NancyCPS
4 Comments
 
LVL 14

Accepted Solution

by:
John-Charles-Herzberg earned 500 total points
Comment Utility
0
 
LVL 38

Expert Comment

by:Aaron Tomosky
Comment Utility
Robocopy.
0
 
LVL 8

Expert Comment

by:subhashchy
Comment Utility

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

try this..

Note that if duplicates found it will not overrite

0
 
LVL 1

Author Closing Comment

by:NancyCPS
Comment Utility
Thanks soooooooooo much.
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

VALIDATING DATES One method of validating dates is to jam the date into the DATE command and see if it accepts it by examining the system's errorlevel value. A non-zero result indicates failure. A typical example might look something like the fol…
YESTERDAY YESTERDAY.BAT is inspired by a previous article I wrote entitled: TOMORROW.BAT (http://www.experts-exchange.com/OS/Microsoft_Operating_Systems/MS_DOS/A_4196-Advanced-Batch-File-Programming-TOMORROW-BAT.html). The crux of this batch f…
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

7 Experts available now in Live!

Get 1:1 Help Now