batch for loop to move files

March 11, 2010 at 06:08:47
Specs: Windows 2003, 4GB
Why do I get a command syntax error with this batch file code?

For %%A in "d:\Sa Files\cmdlinescripts\*.txt") do move %%A "d:\sa files\output"


See More: batch for loop to move files

Report •

#1
March 11, 2010 at 12:15:43
This code works. So has something to do with the path. Still can't figure out how to fix it though.

for %%A in ("*.txt") do move /Y %%A ".\output"


Report •

#2
March 11, 2010 at 12:18:57
I've also tried to add a "delims=" to it but output says that delims was unexpected.

Report •
Related Solutions


Ask Question