Try something like this
$esxi=Get-VMHost-Name$name
$esxi|Select-Object@{N="ESXi";E={$_.Name}},
@{N="CPU";E={$_.ExtensionData.Summary.Hardware.CpuModel}},
@{N="Gateway";E={$_.ExtensionData.Config.Network.IpRouteConfig.defaultGateway}}
Try something like this
$esxi=Get-VMHost-Name$name
$esxi|Select-Object@{N="ESXi";E={$_.Name}},
@{N="CPU";E={$_.ExtensionData.Summary.Hardware.CpuModel}},
@{N="Gateway";E={$_.ExtensionData.Config.Network.IpRouteConfig.defaultGateway}}