Page 1 of 1

file read

Posted: 18 Sep 2009 02:39
by alcool9999
hi i need to read a text file line by line and check each time if that line matches a variable.

Posted: 18 Sep 2009 03:32
by jaffamuffin

Code: Select all

for /f %%A IN (file.txt) DO (
 IF "%%A"=="value" ECHO MATCH
)

Re: file read

Posted: 20 Sep 2009 20:52
by ghostmachine4
alcool9999 wrote:hi i need to read a text file line by line and check each time if that line matches a variable.

use findstr