1.

Solve : run command on many files?

Answer»

Good day all..

Hope this isn't too much of a newbie question. I am trying to run a command line on a SERIES of files, e.g. command -i input.ext -o output.ext

Should I use pipe for this? Or get a list of files in the folder first? There are several hundred files that need to be processed.

Thanks in advance...use this
mkdir outputfils
for /f "delims=" %%i in ('dir /b /a-d') do (
command -i %%i -o out%%i
move "out%%i" "./outputfils/."
)

u should move the file the command create to a sub folder so that the for loop will take it again and go in an infinit loop
Excellent, thank you.

Needs a bit of REFINING on my PART, as there are two files for each bit of data, with different extentions, of which in only need one file as the input name, and a single file for both is generated, but those are only minor bugs, as everything is working as it should. Going to take a while though, it's about 500GB Quote from: andrewgerm on May 14, 2008, 08:50:51 AM

Going to take a while though, it's about 500GB

i thing u will smile like that when it finish successfully
and if not i will be like this
At the moment, I'm not even breathing
Everyone knows thing always fail at 98%...i think u have the hope
just don't be depressed
2% STILL a good ratio It worked... Im' happy...

Thanks again all. Been a while since I did any sort of in depth batch programming...


Discussion

No Comment Found