Click or drag to resize
TapiAppIncomingCall Event
Occurs when a new incoming call is received.

Namespace: Traysoft.AddTapi
Assembly: Traysoft.AddTapi (in Traysoft.AddTapi.dll) Version: 6.0.0.1110
Syntax
public static event TapiEventHandler IncomingCall

Value

Type: Traysoft.AddTapiTapiEventHandler
Remarks
This event occurs when a new incoming call is received on the open line. After a new incoming call is detected, AddTapi.NET waits up to 3 seconds for Caller ID information to arrive before firing this event. Set WaitForCallerID property to false if you want AddTapi.NET to fire this event immediately after a new call is detected.
Note Note
In Windows Forms and WPF applications AddTapi.NET executes the handler of this event on the main thread of the application (the thread that called Initialize(String)). It is safe to access Windows Forms or WPF controls from the event handler without using Invoke mechanism.
Examples
The following code shows how to handle IncomingCall event.
TapiApp.Initialize("MyApp");
TapiApp.IncomingCall += OnIncomingCall;
...

void OnIncomingCall(object sender, TapiEventArgs args)
{
    // Display a message to the user
    Console.WriteLine("Incoming call from {0} on line {1}", args.Call.CallerID, args.Line.Name);
}
See Also