Share via


lineGetAddressID

A version of this page is also available for

Windows Embedded CE 6.0 R3

4/8/2010

This function returns the address identifier associated with an address in a different format on the specified line.

Syntax

LONG WINAPI lineGetAddressID(
  HLINE hLine,
  LPDWORD lpdwAddressID,
  DWORD dwAddressMode,
  LPCWSTR lpsAddress,
  DWORD dwSize 
);

Parameters

  • hLine
    Handle to the open line device.
  • lpdwAddressID
    Pointer to a DWORD-sized memory location where the address identifier is returned. An address identifier is permanently associated with an address; the identifier remains constant across operating system upgrades.
  • dwAddressMode
    Address mode of the address contained in lpsAddress. This parameter uses one and only one of the LINEADDRESSMODE constants. You must specify LINEADDRESSMODE_DIALABLEADDR.
  • lpsAddress
    Pointer to a data structure holding the address assigned to the specified line device. The format of the address is determined by dwAddressMode. Because the only valid value is LINEADDRESSMODE_DIALABLEADDR, lpsAddress uses the common dialable number format and is null-terminated.
  • dwSize
    Size, in bytes, of the address contained in lpsAddress. The size of the string must include the null terminator.

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_INVALLINEHANDLE

The handle to the open line device is invalid.

LINEERR_OPERATIONUNAVAIL

The operation is unavailable.

LINEERR_INVALADDRESSMODE

The address mode is invalid.

LINEERR_OPERATIONFAILED

The operation failed.

LINEERR_INVALPOINTER

The pointer is invalid.

LINEERR_RESOURCEUNAVAIL

The resources are unavailable.

LINEERR_INVALADDRESS

The address is invalid.

LINEERR_UNINITIALIZED

A parameter is unitialized.

LINEERR_NOMEM

Not enough memory is available.

Remarks

The lineGetAddressID function is used to map a phone number (address) assigned to a line device back to its dwAddressID in the range zero to the number of addresses minus one returned in the line's device capabilities. The lineMakeCall function allows the application to make a call by specifying a line handle and an address on the line. The address can be specified as a dwAddressID, as a phone number, or as a device-specific name or identifier. Using a phone number can be practical in environments where a single line is assigned multiple addresses.

Note

This function is for TAPI version 2.0 and later.

Note

LINEADDRESSMODE_ADDRESSID may not be used with lineGetAddressID.

Requirements

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

See Also

Reference

lineMakeCall