Platform SDK: TAPI

TSPI_phoneGetLamp

The TSPI_phoneGetLamp function returns the current lamp mode of the specified lamp.

LONG TSPIAPI TSPI_phoneGetLamp(
  HDRVPHONE hdPhone,    
  DWORD dwButtonLampID, 
  LPDWORD lpdwLampMode  
);

Parameters

hdPhone
The handle to the phone whose lamp mode is to be retrieved.
dwButtonLampID
The identifier of the lamp to be queried.
lpdwLampMode
A pointer to a memory location into which the service provider writes the lamp mode status of the given lamp. This parameter can have at most one of the PHONELAMPMODE_ constants.

Return Values

Returns zero if the function succeeds, or an error number if an error occurs. Possible return values are as follows:

PHONEERR_INVALBUTTONLAMPID, PHONEERR_RESOURCEUNAVAIL, PHONEERR_INVALPHONEHANDLE, PHONEERR_OPERATIONFAILED, PHONEERR_INVALPHONESTATE, PHONEERR_OPERATIONUNAVAIL, PHONEERR_NOMEM.

Remarks

Phone sets that have multiple lamps per button should be modeled using multiple button/lamps pairs. Each additional button/lamp pair should use a DUMMY button.

Requirements

  Windows NT/2000: Requires Windows NT 4.0 SP3 or later.
  Windows 95/98: Requires Windows 95 or later.
  Version: Requires TAPI 1.3 or later.
  Header: Declared in Tspi.h.

See Also

PHONECAPS, PHONELAMPMODE_ Constants, TSPI_phoneGetDevCaps, TSPI_phoneSetLamp