Use FINDSTR with line numbering and work from there:
Code: Select all
T:\>findstr /n /r "^" f9.txt
1:1
2:2
3:3
4:
5:5
6:
7:7:5\;5:6
8:8
9:
T:\>for /f "usebackq tokens=1,* delims=:" %i in (`findstr /n /r "^" f9.txt`) Do @echo __%j__
__1__
__2__
__3__
____
__5__
____
__7:5\;5:6__
__8__
____
T:\>