MSFT_ComputerGroup.GUID Property
Gets the GUID that identifies the computer group.
string MSFT_ComputerGroup.GUID
Access
Read/write
Return Value
String
Remarks
The GUID value is a unique identifier that is assigned to the object at the time it is created. It is also the key property for this WMI class. The GUID is read/write for new objects until they are saved to WMI.
Examples
The following example shows the use of the GUID property.
'*********************************************************************
' Routine: Function GetComputerGroupByGUID
' Purpose: Gets a computer group object matching the specified GUID.
' Arguments: The server running MOM, the group's GUID.
' Returns: Matching MSFT_ComputerGroup object.
'
'**********************************************************************
Function GetComputerGroupByGUID(strMOMServer, strGUID)
Dim objComputerGroup
Dim intMatches
Set objComputerGroup = GetObject("WinMgmts://" & strMOMServer & "/root/MOM:MSFT_ComputerGroup='" & strGUID & "'")
' check for no match
If (objComputerGroup Is Nothing) Then
Err.Description = "Could not find an object matching the specified GUID"
End If
Set GetComputerGroupByGUID = objComputerGroup
End Function
Requirements
Platforms: Requires Windows 2000 Server or later
Version: Requires MOM 2000 SP1 or later