SWbemObjectEx.SystemProperties_屬性

SWbemObjectEx物件的SystemProperties_屬性會傳回SWbemPropertySet物件,其中包含套用至物件的WMI 系統屬性集合。

如需此語法的說明,請參閱 腳本 API 的檔慣例

這是可讀寫的屬性。

Syntax

SWbemObjectEx.SystemProperties_ As Object

屬性值

範例

下列程式碼範例會擷取 Win32_Process 類別的屬性值。

Set objWmi = GetObject ("winmgmts:root\cimv2")
Set objClass = objWmi.Get("Win32_Process")

' SWbemObjectEx.SystemProperties_ returns 
' an SWbemPropertySet object that contains the collection
' of sytem properties for Win32_Process class

For Each objProperty In objClass.SystemProperties_

    WScript.Echo vbCrLf & objProperty.Name & ":"

    ' Have to take into account that
    ' __Derivation is an array

    If Not objProperty.IsArray Then
        WScript.Echo vbTab & objProperty.Value
    Else
        For Each strValue In objProperty.Value
            WScript.Echo vbTab & strValue
        Next
    End If

Next

規格需求

需求
最低支援的用戶端
Windows Vista
最低支援的伺服器
Windows Server 2008
標頭
Wbemdisp.h
類型程式庫
Wbemdisp.tlb
DLL
Wbemdisp.dll
CLSID
CLSID_SWbemObjectEx
IID
IID_ISWbemObjectEx

另請參閱

SWbemObjectEx