我正在寻找一种可以通过VBScript获取连接操纵杆列表的方法,如下图所示(我的意思是它们的顺序非常重要):
答案 0 :(得分:1)
以下是执行此操作的代码...很难在网上找到...
strComputer = "." Set objWMIService = GetObject("winmgmts:" _ &
"{impersonationLevel=impersonate}!\\" & strComputer & "oot\cimv2")
Set colItems = objWMIService.ExecQuery("Select * from
Win32_PnPEntity")
For Each objItem in colItems
Wscript.Echo "Class GUID: " & objItem.ClassGuid
Wscript.Echo "Description: " & objItem.Description
Wscript.Echo "Device ID: " & objItem.DeviceID
Wscript.Echo "Manufacturer: " & objItem.Manufacturer
Wscript.Echo "Name: " & objItem.Name
Wscript.Echo "PNP Device ID: " & objItem.PNPDeviceID
Wscript.Echo "Service: " & objItem.Service
Next
希望this帮助