xCopy Folders using wildcards

  • Thread starter Thread starter jd
  • Start date Start date
J

jd

How does one copy different named folders (and contents), and the only thing
they have in common is ".fol" in their name?


eg..
C:\Banana
C:\Orange.fol
C:\Grape
C:\Peach.fol

To only copy Orange and Peach I tried using:
xcopy C:\*.fol\*.* D:\Backup\ /y

But it tells me no files found...
Using only native windows commands (or scripts) is this possible?
 
I haven't done it yet with cmd.exe (I use shell scripts) but I would try
something like:

for /D %%i in (*.fol) do xcopy %%i D: /S

Type
for /?
in cmd.exe

Armin
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Back
Top