ICancelMethodCalls::Cancel method (objidl.h)
Requests that a method call be canceled.
Syntax
HRESULT Cancel(
[in] ULONG ulSeconds
);
Parameters
[in] ulSeconds
The number of seconds to wait for the server to complete the outbound call after the client requests cancellation.
Return value
This method can return one of these values.
Return code | Description |
---|---|
|
The cancellation request was made. |
|
The call was already canceled. |
|
Call cancellation is not enabled on the thread that is processing the call. |
|
The call was completed during the timeout interval. |
Remarks
The Cancel method only issues a cancel request. A return value of S_OK does not mean that the call was canceled, only that an attempt was made to cancel the call. The behavior of the cancel object on receiving a cancel request is entirely at the discretion of the implementer.
If a method that returns an HRESULT is canceled, the return value will be RPC_S_CALL_CANCELED.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 2000 Professional [desktop apps only] |
Minimum supported server | Windows 2000 Server [desktop apps only] |
Target Platform | Windows |
Header | objidl.h (include ObjIdl.h) |