SWbemObject.Subclasses_ method
Applies to: desktop apps only
The Subclasses_ method of the SWbemObject object returns an SWbemObjectSet object. This object is a collection of subclasses of the current object, which must be a class. Items in the returned collection can be obtained using standard collection methods. For more information, see Accessing a Collection.
For an explanation of this syntax, see Document Conventions for the Scripting API.
Syntax
objWbemObjectSet = .Subclasses_( _ [ ByVal iFlags ], _ [ ByVal objwbemNamedValueSet ] _ )
Parameters
- iFlags [in, optional]
-
Integer that determines how deep the call enumerates. This parameter can accept the following values.
- objwbemNamedValueSet [in, optional]
-
Typically, this is undefined. Otherwise, this is an SWbemNamedValueSet object whose elements represent the context information that can be used by the provider that is servicing the request. A provider that supports or requires such information must document the recognized value names, data type of the value, allowed values, and semantics.
Return value
If the call is successful, an SWbemObjectSet object is returned.
Error codes
After the completion of the Subclasses_ method, the Err object may contain one of the error codes in the following table.
| Error (Name/Dec/Hex) | Meaning |
|---|---|
|
Current user does not have permission to view one or more of the classes returned by the call. |
|
Unspecified error. |
|
Specified class did not exist. |
|
Invalid parameter was specified. |
|
Not enough memory to complete the operation. |
Remarks
It is not an error for the returned collection to have zero elements if there are no subclasses of the current object. The Subclasses_ method only works for class objects.
Examples
For script code examples, see WMI Tasks for Scripts and Applications and the TechNet ScriptCenter Script Repository.
Requirements
|
Minimum supported client | Windows 2000 Professional |
|---|---|
|
Minimum supported server | Windows 2000 Server |
|
Type library |
|
|
DLL |
|
See also
Send comments about this topic to Microsoft
Build date: 3/9/2012