Powershell script that will place the Wmi computersysten model property into a variable

Hi,

Tried  to script with Get-WmiObject -Class Win32_ComputerSystem -Property model. I want to write the model into a Variable and haven't had much luck?

Thanks!

August 25th, 2015 2:07pm

This should work.

$variable = (Get-WmiObject -Class Win32_ComputerSystem -Property model).Model

You included the Model property but other default properties are also returned. You need to single out the Model property.

Free Windows Admin Tool Kit Click here and download it now
August 25th, 2015 3:46pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics