Return Manufacturer of Workstation

This will return the manufacturer of a computer.

VBScript

On Error Resume Next

strComputer = “.”
Set objWMIService = GetObject(“winmgmts:” & “{impersonationLevel=impersonate}!\\” & strComputer & “\root\cimv2”)
Set colItems = objWMIService.ExecQuery _
(“Select * from Win32_ComputerSystem”)
For Each objItem in colItems
Wscript.Echo “Manufacturer: ” & objItem.Manufacturer
next

Command Line

wmic csproduct get vendor

email me