how can I copy all .png files in my current directory to a folder in my current directory called "src"?

I tried this code:

copy .*.png /src 

and it didn't work for me.

link|improve this question
feedback

migrated from stackoverflow.com Apr 27 '11 at 17:35

This question came from our site for professional and enthusiast programmers.

3 Answers

remove the forward slash so

copy *.png src
link|improve this answer
We have a winner! – Linker3000 Apr 27 '11 at 19:27
feedback

You had an extra period in the source, try this :

copy *.png /src
link|improve this answer
..and that states src is off the root and not a local subfolder - remove the slash. – Linker3000 Apr 27 '11 at 19:25
feedback

If the src subdirectory exists...try

copy *.png .\src\*.png
link|improve this answer
Way overcomplicated – Linker3000 Apr 27 '11 at 19:26
... but nonetheless correct where other answers placed the target directory in the root directory, and also not prone, as other answers are, to silently doing something quite different to what the questioner desired whenever there's no directory named "src". – JdeBP May 16 '11 at 11:44
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.