FIND command Question

Hewlett-packard / Sd2100
May 31, 2009 at 08:38:32
Specs: Windows XP, 1024
ok i want to count the number of lines in a txt file but want the result in a variable.


find /v /c "&*fake&*" test.txt will do what i want

but i dont want

------->C:\test.txt "some number"

i want to show something like


thank you
Brock
echo %var% number


See More: FIND command Question

Report •


#1
May 31, 2009 at 08:59:38
@echo off
for /F %%a in ('type "C:\test.txt" ^| find /C /V ""') do set myVar=%%a
echo There are %myVar% Lines


Report •

#2
May 31, 2009 at 12:04:22
Thank you that is what i needed

Report •

Related Solutions


Ask Question