Format Azure PowerShell cmdlet output

Formatting is used for display in the PowerShell console, and conversion is used for generating data to be consumed by other scripts or programs.

Get-AzVM -ResourceGroupName QueryExample |
  Format-Table -Property Name, ResourceGroupName, Location
Get-AzVM | Format-List
Get-AzVM | Format-List -Property ResourceGroupName, Name, Location
Get-AzVM | Format-Wide
Get-AzVM | Format-Custom -Property Name, ResourceGroupName, Location, OSProfile

Last updated