TapiCallGetCommHandle Method |
Namespace: Traysoft.AddTapi
Exception | Condition |
---|---|
TapiDisconnectException | The call has been already disconnected. |
TapiException | AddTapi.NET cannot obtain a handle because a TAPI error occurred. |
GetCommHandle obtains a handle of the open communication port of the data modem. Returned handle can be used to transfer data between the application and the remote terminal. The telephony service provider opens the port in overlapped I/O mode and configures the port using the settings specified in the Control Panel. The application can set additional configuration options for the device by using communications functions with the returned handle.
The application assumes ownership of the returned handle. The handle must be closed using CloseHandle Win32 function before the call is disconnected (before calling Disconnect). We recommend using SafeFileHandle wrapper to manage the returned handle.