troubleshooting Question

Need a batch file to copy a file to multiple subfolders

Avatar of bpl5000
bpl5000 asked on
Windows BatchShell Scripting
13 Comments1 Solution1149 ViewsLast Modified:
I need a batch file that will copy a file (desktop.ini) into multiple subfolders, but only one layer deep.  For example, in c:\temp... I want it to copy the file into:

c:\temp\folder1
c:\temp\folder2
c:\temp\folder3

But not into...
c:\temp\folder1\subfolder1
c:\temp\folder2\subfolder2
etc.

I just want to copy the file into subfolders that are in the root of the temp folder.  I will be running this command on a Windows 2008 server.  Any help would be greatly appreciated!
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 13 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 13 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros