Shut up Test-NetConnection!

Ever get tired of seeing this when you use the test-netconnection command?

Me too. I like nice neat readable outputs and test-netconnection is particularly ugly.

I’ve had been dealing with it for years brushing it off like an annoying gnat that’s frustrating, but not quite bad enough to make you go get the flamethrower to deal with it. Until I had enough and found the flamethrower…….

All it really took was adding the below to the command:

-ErrorAction SilentlyContinue -WarningAction SilentlyContinue

So your command would look something like this:

$list | test-netconnection -ErrorAction SilentlyContinue -WarningAction SilentlyContinue

Ahhhh, so much better! I should have done this way sooner.