Looks up details of any Azure Resource Manager (ARM) Virtual Machines across whatever subscriptions you have access to, and writes them to a .CSV file. This allows you to easily analyse the details in Excel, for example to show charts or Pivot Tables listing VMs by size, status, location, etc.  

Writes the following information about each VM:



.\DumpARMVMs.ps1 [-TenantId <Tenant name or GUID>] [-File <Path to CSV output>]
If you omit -TenantId then the file will contain VMs from all subscriptions across all Azure Active Directory tenants you can access.

If you omit -File then the file will be written to "Azure-ARM-VMs.csv" in the current directory.

To do the same with Classic (ASM) VMs, see Dump Azure Classic VMs to CSV.