TUISPIDLLCALLBACK callback function (tspi.h)

The DllCallbackProc function is called by the UI DLL to send a private parameter block to the service provider. Each invocation of the callback results in a call to the TSPI_providerGenericDialogData function in the service provider associated with the specified object. The contents of the parameter block are defined by the service provider and UI DLL. The service provider can modify the contents of the parameter block; when this function returns, TAPI copies the modified data back into the original UI DLL parameter block.

The TUISPIDLLCALLBACK type defines a pointer to this callback function. DllCallbackProc is a placeholder for the application-defined function name.

Syntax

TUISPIDLLCALLBACK Tuispidllcallback;

LONG Tuispidllcallback(
  DWORD_PTR dwObjectID,
  DWORD dwObjectType,
  LPVOID lpParams,
  DWORD dwSize
)
{...}

Parameters

dwObjectID

An object identifier of the type specified by dwObjectType.

dwObjectType

One of the TUISPIDLL_OBJECT_ constants, specifying the type of object identified by dwObjectID

TUISPIDLL_OBJECT_LINEID

The dwObjectID parameter is a line device identifier (dwDeviceID). This is used when the callback is invoked during the processing of TUISPI_lineConfigDialog or TUISPI_lineConfigDialogEdit.

TUISPIDLL_OBJECT_PHONEID

The dwObjectID parameter is a phone device identifier (dwDeviceID). This is used when the callback is invoked during the processing of TUISPI_phoneConfigDialog.

TUISPIDLL_OBJECT_PROVIDERID

The dwObjectID parameter is a permanent provider identifier. This is used when the callback is invoked during the processing of TUISPI_providerConfig, TUISPI_providerInstall, or TUISPI_providerRemove.

TUISPIDLL_OBJECT_DIALOGINSTANCE

The dwObjectID parameter is an HDRVDIALOGINSTANCE, as returned to the service provider when it sent a LINE_CREATEDIALOGINSTANCE message. This is used when the callback is invoked during the processing of TUISPI_providerGenericDialog.

lpParams

Pointer to a memory area used to hold a parameter block.

dwSize

The size in bytes of the parameter block.

Note  If the size parameters in the structure are not correct, there is a possibility that data could get overwritten. For more information on setting structure sizes, see the memory allocation topic.
 

Return value

Returns zero if successful, or one of these negative error values:

LINEERR_INVALPARAM, LINEERR_INVALPOINTER, LINEERR_NOMEM, LINEERR_OPERATIONFAILED.

Requirements

Requirement Value
Target Platform Windows
Header tspi.h

See also

LINE_CREATEDIALOGINSTANCE

TSPI_providerGenericDialogData

TUISPIDLL_OBJECT_

TUISPI_lineConfigDialog

TUISPI_lineConfigDialogEdit

TUISPI_phoneConfigDialog

TUISPI_providerConfig

TUISPI_providerGenericDialog

TUISPI_providerInstall

TUISPI_providerRemove