I am using the command
for /F %x in ('findstr /r /n "ERROR" C:\temp\test.log ^| find /C ":"') do echo %x
and its returing C:\Windows\system32>echo 23
Its working fine. But my problem is that I need only 23 not the whole string. Please help me. Thanks in advance.