Initiates a transfer request to the remote participant.

Namespace:  Microsoft.Rtc.Collaboration.AudioVideo
Assembly:  Microsoft.Rtc.Collaboration(in Microsoft.Rtc.Collaboration.dll)

Syntax

Visual Basic (Declaration)
Public 
Function 
BeginTransfer ( _
	
callToReplace 
As 
Call, _
	
callTransferOptions 
As 

CallTransferOptions, _
	
userCallback 
As 
AsyncCallback, _
	
state 
As 
Object _
) 
As 
IAsyncResult
C#
public 
IAsyncResult 
BeginTransfer(
	
Call 
callToReplace,
	

CallTransferOptions 
callTransferOptions,
	
AsyncCallback 
userCallback,
	
Object 
state
)
Visual C++
public:
IAsyncResult^ 
BeginTransfer(
	
Call^ 
callToReplace, 
	

CallTransferOptions^ 
callTransferOptions, 
	
AsyncCallback^ 
userCallback, 
	
Object^ 
state
)
JavaScript
function 
beginTransfer(
callToReplace, 
callTransferOptions, 
userCallback, 
state);

Parameters

callToReplace
Type: Microsoft.Rtc.Collaboration . . :: . Call
The call to be replaced.
callTransferOptions
Type: Microsoft.Rtc.Collaboration . . :: . CallTransferOptions
Call transfer options. This parameter can be null.
userCallback
Type: AsyncCallback
The method to be called when the asynchronous operation is completed.
state
Type: Object
A user-provided object that distinguishes this particular asynchronous operation from other asynchronous operations.

Return Value

An IAsyncResult that references the asynchronous operation.

Remarks

Initiates a transfer request to the remote participant, of the current call to replace another existing call in Attended mode.

This is a Supervised transfer since the operation involves another call and it waits for success/failure notifications from the remote participant regarding how the transfer is being carried out at the remote side. When the transfer is successfully completed by the existing remote participant, the current call is terminated. If it fails, the call is not affected.

If callToReplace is passed as the instance of the call initiating the transfer, then this would be considered as the self-transfer.

Exceptions

Exception Condition
ArgumentNullException Thrown when the callToReplace>value is null.
ArgumentException Thrown when the callTransferOptions>parameter is specified with unsupported headers, or is used to override transferor value by any endpoint other than an Application Endpointor is of type Unattended transfer.
InvalidOperationException Thrown when the callToReplaceis not in the Established stateor the current call is not in a valid state to initiate a transfer operation.

See Also