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 manipulates the toll list.

Note:
This function is for TAPI version 2.0 and later.

Syntax

LONG WINAPI lineSetTollList(
  HLINEAPP 
hLineApp,
  DWORD 
dwDeviceID,
  LPCWSTR 
lpszAddressIn,
  DWORD 
dwTollListOption
);

Parameters

hLineApp

Application handle returned by the lineInitializeExfunction. If an application has not yet called the lineInitializeExfunction, it can set the hLineAppparameter to NULL.

dwDeviceID

Device identifier for the line device on which the call is intended to be dialed, so that variations in dialing procedures on different lines can be applied to the translation process.

lpszAddressIn

Pointer to a null-terminated string containing the address from which the prefix information is to be extracted for processing. This parameter must not be NULL, and it must be in the canonical address format.

dwTollListOption

Toll list operation to be performed. The following table shows the values this parameter can take. This parameter uses one and only one of these constants.

Value Description

LINETOLLLISTOPTION_ADD

A prefix is to be added to the toll list.

LINETOLLLISTOPTION_REMOVE

A prefix is to be removed from the toll list.

Return Value

Returns zero if the request succeeds or a negative error number if an error occurs. The following table shows the return values for this function.

Value Description

LINEERR_BADDEVICEID

The device identifier is incorrect.

LINEERR_NODRIVER

The driver was not found.

LINEERR_INVALAPPHANDLE

The application handle is invalid.

LINEERR_NOMEM

Not enough memory is available.

LINEERR_INVALADDRESS

The address is invalid.

LINEERR_OPERATIONFAILED

The operation failed.

LINEERR_INVALPARAM

A parameter is invalid.

LINEERR_RESOURCEUNAVAIL

The resources are unavailable.

LINEERR_INIFILECORRUPT

The INI file is corrupted.

LINEERR_UNINITIALIZED

A parameter is uninitialized.

LINEERR_INVALLOCATION

The allocation is invalid.

Requirements

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

See Also