Thursday, January 14, 2021

Printing Windows 10 network adapter port speed with Powershell

My working Powershell revision:
Get-WmiObject -Class Win32_NetworkAdapter | `
    Where-Object { $_.Speed -ne $null -and $_.MACAddress -ne $null } | `
    Format-Table Name, `
    @{Label='Connected'; Expression={-not $_.OperationalStatusDownMediaDisconnected}}, `
    @{Label='Speed(MB)'; Expression = {$_.Speed/1000000}}, `
    FullDuplex,InterfaceDescription

No comments:

Post a Comment