Powershell with WMI

Managing Systems with PowerShell and WMI

PS C:\> get-wmiobject win32_share
PS C:\> get-wmiobject win32_Processor

Example 1.)ListWMIProperties.ps1
$class=Read-Host "Enter a Win32 WMI Class that you are interested in"
$var=get-WMIObject -class $class -namespace "root\Cimv2"
$properties=$var | get-member -membertype Property
Write-Host "Properties for "$Class.ToUpper()
foreach ($property in $properties) {$property.name}