IWbemContext::GetNames method (wbemcli.h)
The IWbemContext::GetNames method returns a SAFEARRAY structure of all of the names of the named context values. After all the names are known, 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.
HRESULT GetNames( [in] long lFlags, [out] SAFEARRAY **pNames );
Reserved. This parameter must be 0.
This parameter cannot be NULL, but on entry it must point to NULL. If no error is returned, on exit pstrNames receives a pointer to a new SAFEARRAY structure of type VT_BSTR containing all the context value names. The caller must call SafeArrayDestroy on the returned pointer when the array is no longer required. If an error code is returned, the pointer is left unmodified.
This method returns an HRESULT indicating the status of the method call. The following list lists the value contained within an HRESULT.
For more information about using SAFEARRAY structures of BSTR values, see Retrieving Part of a WMI Instance.
|Minimum supported client||Windows Vista|
|Minimum supported server||Windows Server 2008|
|Header||wbemcli.h (include Wbemidl.h)|
|DLL||Esscli.dll; Fastprox.dll; FrameDyn.dll; FrameDynOS.dll; Wbemcomn.dll; Wbemcore.dll; Wbemess.dll; Wmipjobj.dll|