pipe it to | find /C
or to exclude blank lines pipe it to | find /c /v ""
example
netstat -an | findstr ESTAB | find /c /v ""