DWbemContext.GetNames

[This is preliminary documentation and subject to change.]

The DWbemContext.GetNames method returns an array of strings containing all of the names of the named context values. After all the names are known, you can use GetValue can be called on each name to retrieve the value. This technique is a way of accessing the context values that is different from calling the BeginEnumeration, Next, and EndEnumeration methods.

GetNames(
  [in] lFlags  Long Long,
  [out] pNames()  As String
) As Long
 

Parameters

lFlags
Reserved. It must be zero.
pNames
This parameter cannot be vbNullString. If no error is returned, pNames receives an array containing all the context value names. If an error code is returned, pNames is set to vbNullString.

Note  If there are no named values in the object, the call succeeds and returns an array of length zero.

Return Values

WBEM_E_INVALID_PARAMETER An invalid parameter was specified, or the namespace could not be parsed.
WBEM_E_OUT_OF_MEMORY There was not enough memory to complete the operation.
WBEM_NO_ERROR Success.

See Also

DWbemContext.GetValue, DWbemContext.BeginEnumeration