Link to home
Create AccountLog in
Avatar of John Darby
John DarbyFlag for United States of America

asked on

using findstr to output

The other day I used a command that worked fine, but its output required me to do some hands-on work in Excel to get exactly the output I wanted to copy/paste into an email.

Here was the command (sample IP)...

ping -a 10.10.10.10 | findstr /i "Pinging" >> .\hostnames.txt

I am looking for a way to grep or findstr only the hostname. Do you know if I can do this simply using the old CMD tools?

Thanks!
JohnD
ASKER CERTIFIED SOLUTION
Avatar of fhmc
fhmc

Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
SOLUTION
Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Avatar of John Darby

ASKER

The clipboard...never knew how to do that. Thanks bro!
You rock, my friend...thank you!