本帖最后由 czjt1234 于 2013-3-21 11:08 编辑
- Set objSWbemLocator = CreateObject("WbemScripting.SWbemLocator")
- Set objSWbemServices = objSWbemLocator.ConnectServer()
- Set objSWbemObject = objSWbemServices.Get("win32_service")
- Set objSWbemQualifierSet = objSWbemObject.Properties_.Item("CreationClassName").Qualifiers_
- strQualifier = "该类的限定符的个数:" & objSWbemQualifierSet.Count & vbCrLf & vbCrLf
- For Each objSWbemQualifier In objSWbemQualifierSet
- strQualifier = strQualifier & objSWbemQualifier.Name & vbCrLf
- Next
- Msgbox strQualifier
- Msgbox "cim_key限定符的值:" & objSWbemQualifierSet.Item("cim_key").Value
复制代码 在http://msdn.microsoft.com/en-us/library/aa393650.aspx中没有cim_key这个限定符类型啊?
还有http://msdn.microsoft.com/en-us/library/windows/desktop/aa394418(v=vs.85).aspx里
说CreationClassName属性
CreationClassName
Data type: string
Access type: Read-only
Qualifiers: MaxLen (256)
有限定符MaxLen,但上述代码里并没有显示,什么原因? |