Using Out-GridView
- Dominant language
- Python
- Stars
- 4.6k
- Forks
- 3.5k
- Avg merge
- 3d 2h
- Merged PRs (30d)
- 60
Description
[Enter feedback here]
To Convert a list of location into an Powershell Object list:
`(az account list-locations | ConvertFrom-Json).ForEach({$_ | Select-Object -Property @{N='physicalLocation'; E={$_.metadata.physicalLocation}}, Name})`
Put it in a variable:
` $a = (az account list-locations | ConvertFrom-Json)`
List it into GridView:
` $a | ogv`
Select Name and Physical Location and put it in a variable:
` $b = (az account list-locations | ConvertFrom-Json).ForEach({$_ | Select-Object -Property @{N='physicalLocation'; E={$_.metadata.physicalLocation}}, Name})`
List that into GridView:
` $b | ogv`
---
#### Document Details
⚠ *Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.*
* ID: 9abfaa54-0895-29f7-f3bb-ff604912b2ac
* Version Independent ID: d1ff3478-8a86-59e4-62ef-449900132a67
* Content: [az account](https://docs.microsoft.com/en-us/cli/azure/account?view=azure-cli-latest)
* Content Source: [latest/docs-ref-autogen/account.yml](https://github.com/MicrosoftDocs/azure-docs-cli/blob/master/latest/docs-ref-autogen/account.yml)
* Service: **azure**
* GitHub Login: @rloutlaw
* Microsoft Alias: **routlaw**
Contributor guide
Assessment
This issue has not been assessed yet.