Search found 3 matches

by jargen
26 Oct 2011 15:03
Forum: DOS Batch Forum
Topic: Bat file, count lines in if statement.
Replies: 5
Views: 4448

Re: Bat file, count lines in if statement.

It does that no matter what how many lines the txt file has.
by jargen
26 Oct 2011 08:23
Forum: DOS Batch Forum
Topic: Bat file, count lines in if statement.
Replies: 5
Views: 4448

Re: Bat file, count lines in if statement.

Thanks for the help however it dosent appear to quite be working. I changed the txt file to the correct name and changed exit to pause (to do some debugging) and i get this C:\Users\Jargen>for /F %C in ('type programs.txt | find /c /i "<TD"') do if %C L EQ 2 pause /b C:\Users\Jargen>if 0 L...
by jargen
26 Oct 2011 07:26
Forum: DOS Batch Forum
Topic: Bat file, count lines in if statement.
Replies: 5
Views: 4448

Bat file, count lines in if statement.

I know how to count the number of lines using console: FIND /C /I "<TD" example.html
However how do i make a if statement so if the lines are above 100 then it executes a command, but if not simply exits?


Any help is appreciated.
Thanks,