Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
A version of this page is also available for
4/8/2010

This function installs a telephony service provider.

Syntax

LONG lineAddProvider(
  LPCWSTR 
lpszProviderFilename,
  HWND 
hwndOwner,
  LPDWORD lpdwPermanentProviderID
);

Parameters

lpszProviderFilename

Pointer to a null-terminated string that contains the path of the service provider DLL to be added.

hwndOwner

Handle to a window in which any dialog boxes that need to be displayed as part of the installation process would be attached. Can be NULL to indicate that any window created during the function should have no owner window.

lpdwPermanentProviderID

Pointer to a DWORD-sized memory location into which TAPI writes the permanent provider identifier of the newly installed service provider. This parameter can be NULL.

Return Value

Zero indicates success. A negative error number indicates that an error occurred. The following table shows the return values for this function.

Value Description

LINEERR_INIFILECORRUPT

Corrupted INI file

LINEERR_NOMEM

Not enough memory

LINEERR_INVALPARAM

Invalid parameter

LINEERR_NOMULTIPLEINSTANCE

Multiple instances not found

LINEERR_INVALPOINTER

Invalid pointer

LINEERR_OPERATIONFAILED

The operation failed

Remarks

In Windows Embedded CE, TAPI uses a function pointer table to call the service provider instead of using exported ordinal entry points. In lineAddProvider, TAPI calls the service provider's exported TSPI_lineGetProcTablefunction. This is the only function that a service provider must export. Then, TAPI calls the service provider's TSPI_providerInstall, TSPI_lineNegotiateTSPIVersion, TSPI_providerInit, and TSPI_providerEnumDevices.

Requirements

Header tapi.h
Library coredll.lib
Windows Embedded CE Windows CE 2.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also