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 shuts down the service provider. The service provider terminates any activities it has in progress and releases any resources it has allocated.

Syntax

LONG TSPIAPI TSPI_providerShutdown(
  DWORD 
dwTSPIVersion,
  DWORD 
dwPermanentProviderID 
);

Parameters

dwTSPIVersion

Version of the TSPI definition under which this function must operate. The caller can use the TSPI_lineNegotiateTSPIVersionor TSPI_phoneNegotiateTSPIVersionfunction with the special dwDeviceIDINITIALIZE_NEGOTIATION to negotiate a version that is guaranteed to be acceptable to the service provider.

dwPermanentProviderID

This parameter allows the service provider to determine which among multiple possible instances of the service provider is being shut down. The value of the parameter is identical to that passed in the parameter of the same name in the TSPI_providerInitfunction.

Return Value

Returns zero if the function succeeds, or an error number if an error occurs. Possible return values are LINEERR_INCOMPATIBLEAPIVERSION and LINEERR_NOMEM.

Remarks

The final paired call to this function must be the last call to any of the TSPI functions prefixed with TSPI_lineor TSPI_phoneother than TSPI_lineNegotiateTSPIVersionor TSPI_phoneNegotiateTSPIVersion. It is the caller's responsibility to ensure this.

This function should always succeed except in extraordinary circumstances. Most callers will probably ignore the return code because they will be unable to compensate for any error that occurs. The specified return values are more advisory for development diagnostic purposes than anything else.

There is no directly corresponding function in TAPI. In TAPI, multiple different usage instances can be outstanding, with an "application handle" parameter to identify the instance to be operated on. In TSPI, the interface architecture supports only a single usage instance for each distinct service provider.

Requirements

Header tapicomn.h
Library coredll.lib
Windows Embedded CE Windows CE 3.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also