Partager via


IWMDMProgress3::End3

banner art

The End3 method indicates that an operation is finished. This method extends IWMDMProgress2::End2 by providing additional input parameters for the identification (ID) of the event and for a pointer to the context of the commands.

Syntax

HRESULT End3(
  GUID  EventId,
  HRESULT  hrCompletionCode,
  OPAQUECOMMAND*  pContext
);

Parameters

EventId

[in]  GUID containing the event ID for which progress notifications are being sent.

hrCompletionCode

[in]  HRESULT containing the completion code of the operation that was in progress.

pContext

[in, out]  Pointer to the context of commands that contain any data associated with the event. This parameter is optional and can be NULL..

Return Values

The method returns an HRESULT. All the interface methods in Windows Media Device Manager and service provider can return any of the following classes of error codes:

  • Standard COM error codes
  • Windows error codes converted to HRESULT values
  • Windows Media Device Manager error codes

For a complete list of possible error codes, see Error Codes.

Possible values include, but are not limited to, those in the following table.

Return code Description
S_OK The method succeeded.

Remarks

The interface that owns the method that is implementing an operation calls End3 when the operation defined by the method is completed.

The event ID uniquely identifies the operation. This ID is defined by the component generating the event. The Microsoft implementation of Windows Media Device Manager defines the EVENT_WMDM_CONTENT_TRANSFER event ID, which signifies the content-transfer event.

The hrCompletionCode parameter is the return code of the operation that ended. This parameter can be any HRESULT, including standard COM error codes, Win32 error codes converted to HRESULT, or Windows Media Device Manager error codes.

The context structure is a way for the component to send any relevant data with the event to the application. The component sending this structure should define how the application can interpret this data structure.

Windows Media Device Manager ignores any return code returned by the End3 method because the current operation is finished or terminated before this method is called.

Requirements

Header: Defined in wmdm.idl.

Library: mssachlp.lib

See Also