ThbTapiLine.AddToConference
Unit: hbTapi

Adds a consultation call to an existing conference call. The conference call is passed throug the ConfCall and the consultation call is passed by the ConsultCall parameter. In general, the consult call is in the connected state and then conference call is another call on the same line (and address) that is in the onHoldPendConf state. The conference call can be created e.g. by calling the call's SetupConference method or manually by the phone device.

procedure TForm1.Button1Click(Sender: TObject);
var Call: ThbTapiCall;
begin
  Call1 := GetConferenceCall; // selcet a conference call
  Call2 := GetConnectedCall; // select the active call
  if (Call1 = nil) or (Call2 = nil) then
    Exit;
  try
    hbTapiLine1.AddToConference(Call1, Call2);
  except
    on EhbTapiError do
      MessageDlg('AddToConference failed!', mtError, [mbOK], 0);
  end;
end;


This method is designed for the expert user who wants to select the participating calls by his own. You are also able to use the call's AddToConference method which selects the conference resp. the primary call automatically.

Declaration

procedure AddToConference(ConfCall, ConsultCall: ThbTapiCall);

Remarks

Using this method causes the TAPI function lineAddToConference function to be called. This function works in an asynchronous manner. See the chapter "The Synchronous / Asynchronous Model" and the ThbTapiLine.Options.SyncMode property to read more about the handling of asynchronous functions.

Errors

Using this function may cause an EhbTapiError exception. Possible errors are:

LINEERR_CONFERENCEFULL, LINEERR_NOTOWNER, LINEERR_INVALCONFCALLHANDLE, LINEERR_OPERATIONUNAVAIL, LINEERR_INVALCALLHANDLE, LINEERR_OPERATIONFAILED, LINEERR_INVALCALLSTATE, LINEERR_RESOURCEUNAVAIL, LINEERR_NOMEM, LINEERR_UNINITIALIZED.

See Also

PrepareAddToConference, Establish a Conference Call, ThbTapiCall.ConferenceCall