1.

Solve : reading from a file in DOS?

Answer»

I have a W2K OPERATING system and have written a DOS BATCH file to copy files held in different folders (all in the same location) to another location. Occasionally, the folders change, as new ONES are added. The batch file then needs to be updated. If I write the list of folders to a text file, is it possible to read the name of each folder from the file, a line at a TIME, so that the main batch file can then use the text file to check every folder for files that need to be copied?u can use the for command like this

for /f %%i in (filename) do ECHO %%i

where i will be the lines u put inside the file



Discussion

No Comment Found