TAPI Callback Function

TAPI sends messages to an application through a callback function implemented by the application. Implement the callback function according to the following definition.

void CALLBACK LineCallbackFunc (DWORD hDevice, DWORD dwMsg, DWORD wCallbackInstance, DWORD dwParam1, DWORD dwParam2, DWORD dwParam3);
hDevice
A handle to the line device associated with the callback. Do not use the HANDLE type for this parameter.
dwMsg
The line device message. Line device messages are described in the following table.
Message Description
LINE_ADDRESSSTATE Indicates that the status of an address on a currently open line has changed
LINE_CALLINFO Indicates that call information has changed
LINE_CALLSTATE Indicates that the status of the call has changed
LINE_CLOSE Indicates that the line device has been forcibly closed
LINE_CREATE Indicates that a new line device has been created
LINE_DEVSPECIFIC Indicates that a device-specific event has occurred
LINE_LINEDEVSTATE Indicates that the state of a line device has changed
LINE_REMOVE Indicates that a device has been removed, usually for good
LINE_REPLY Reports the results of function calls that completed asynchronously
LINE_REQUEST Reports the arrival of a new request from another application

dwCallbackInstance
The callback instance data.
dwParam1
A message parameter, used as needed to send additional information.
dwParam2
A message parameter, used as needed to send additional information.
dwParam3
A message parameter, used as needed to send additional information.