WdDuplicateCancellationHandle
Duplicates an existing WdCancellationHandle.Syntax
Parameters
_In_ cancellationHandleType: WdCancellationHandle The cancellation handle to duplicate.
_Out_ duplicatedHandleType: WdCancellationHandle* Receives the duplicated cancellation handle. The caller is responsible for closing this handle independently by calling WdCloseCancellationHandle.
Return value
Type: HRESULT ReturnsS_OK if successful; otherwise, returns an error code.
Remarks
UseWdDuplicateCancellationHandle when multiple components need to reference the same cancellation handle. Both the original and duplicated handles refer to the same cancellation state — signaling cancellation via WdCancelRemoteCopy on either handle cancels the associated WdRemoteCopy operation. Each handle must be closed independently with WdCloseCancellationHandle.
