To export a list of virtual machine attributes, using a text file for input, we can use the following PowerCli code:
Get-VM -Name (Get-Content c:\vmnames.txt) | Select Name,NumCpu,MemoryMB | Export-Csv C:\test.csv -NoTypeInformation -UseCulture
To export a list of virtual machine attributes, using a text file for input, we can use the following PowerCli code:
Get-VM -Name (Get-Content c:\vmnames.txt) | Select Name,NumCpu,MemoryMB | Export-Csv C:\test.csv -NoTypeInformation -UseCulture