IWbemCallResult::GetResultServices

[This is preliminary documentation and subject to change.]

You can use the IWbemCallResult::GetResultServices method to retrieve the IWbemServices pointer, which resulted from a semisynchronous call to IWbemServices::OpenNamespace when it becomes available.

HRESULT GetResultServices(
  [in] LONG lTimeout,
  [out] IWbemServices **ppServices
);
 

Parameters

lTimeout
Specifies the maximum time in milliseconds you must wait for the call to return. If you use the Win32® constant INFINITE (0xFFFFFFFF) is used, the call will block until the interface pointer is available. If you use zero, the call immediately returns either the pointer or a status code.
ppServices
This parameter cannot be NULL. It receives a pointer to the IWbemServices interface requested by the original call to OpenNamespace when it becomes available The caller must call Release on the returned object when it is no longer required.

On error, a new object is not returned.

Return Values

WBEM_NO_ERROR The call succeeded and returned an IWbemServices pointer.
WBEM_S_PENDING The time-out occurred and the call has not yet completed.
WBEM_E_UNEXPECTED An internal failure occurred.
WBEM_E_TRANSPORT_FAILURE The network transport to CIMOM has failed.
WBEM_E_ACCESS_DENIED The user attempted to perform an unauthorized operation.

On error, the COM function GetErrorInfo can be called to obtain more error information.

See Also

IWbemServices::OpenNamespace