I am have tried it several different ways (using -class) and I get:
Get-WmiObject : Invalid parameter
At line:3 char:25
+ $server | Get-WmiObject <<<< Win32_OperatingSystem -computername $_ | select Caption,ServicePackMajorVersion | export-csv "c
:\quiz\results\.csv" -noType
+ CategoryInfo : InvalidOperation: (:) [Get-WmiObject], ManagementException
+ FullyQualifiedErrorId : GetWMIManagementException,Microsoft.PowerShell.Commands.GetWmiObjectCommand
My eventual goal is pull
Get-WmiObject
Win32_BIOS –comp $_.Name | Select SerialNumber
Get-WmiObject
Win32_ComputerSytem –comp $_.Name | Select model,manufacturer
All in the same script.