在这里,我有接受电话的方式,但当有人打电话给我时,它拒绝这里是我尝试过的但是仍然没有工作传出电话正在工作但是来电不能帮助我吗?有一点是alawys显示我呼叫状态忙
static void call_CallStateChanged(object sender, CallStateChangedArgs e)
{
Console.WriteLine("Call state: {0}.", e.State);
if (e.State == CallState.Answered)
SetupDevices();
}
static void RegisterAccount(SIPAccount account)
{
try
{
phoneLine = softphone.CreatePhoneLine(account);
phoneLine.RegistrationStateChanged += line_RegStateChanged;
softphone.IncomingCall += softphone_IncomingCall;
softphone.RegisterPhoneLine(phoneLine);
}
catch (Exception ex)
{
MessageBox.Show("Error during SIP registration: " + ex);
}
我尝试过:
static void softphone_IncomingCall(object sender, VoIPEventArgs e)
{
call = e.Item;
call.CallStateChanged += call_CallStateChanged;
call.Answer();
}