DIWbemObjectSink.SetStatus

[This is preliminary documentation and subject to change.]

Sources call the DIWbemObjectSink.SetStatus method to indicate the end of a notification sequence or the result code of an asynchronous method of DIWbemServices.

Normally, a client implements the DIWbemObjectSink interface, The client executes DIWbemServices methods, which return their results using this interface. During this operation, CIMOM calls Indicate as many times as required, followed by a final call to SetStatus.

DIWbemObjectSink.SetStatus(
  [in] lFlags As Long,
  [in] hResult As Long, 
  [in] strParam As Long, 
  [in] pObjParam As Object
) As Long
 

Parameters

lFlags
Reserved. It must be zero.
hResult
Set to the HRESULT of the asynchronous operation or notification. Typically, this is one of the WBEM_E_ error codes or WBEM_S_ status codes.
strParam
Receives a string if the original asynchronous operation returns a string. For example, when you are using PutInstanceAsync, DIWbemObjectSink.SetStatus is called with this parameter set to the object path of the newly created instance.
pObjParam
Object of type DWbemClassObject. In cases where a complex error or status object is returned, this contains an instance object that contains more information about the error.

Return Values

WBEM_E_FAILED The receiver did not process the notification properly.
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 The call succeeded; the receiver acknowledges the notification.