lineSetAgentStateEx function

The lineSetAgentStateEx function sets the agent state associated with a particular agent handle. It generates a LINE_PROXYREQUEST message to be sent to a registered proxy function handler, referencing a LINEPROXYREQUEST structure of type LINEPROXYREQUEST_SETAGENTSTATEEX.

Syntax

LONG lineSetAgentStateEx(
  HLINE  hLine,
  HAGENT hAgent,
  DWORD  dwAgentState,
  DWORD  dwNextAgentState
);

Parameters

hLine

Handle to the line device.

hAgent

Identifier of the agent whose information is to be changed.

dwAgentState

New agent state. Must be one of the LINEAGENTSTATEEX_ constants, or zero to leave the agent state unchanged and modify only the next state.

dwNextAgentState

Next agent state. Must be one of the LINEAGENTSTATEEX_ constants or zero.

Return value

Returns a request identifier if the asynchronous operation starts; otherwise, the function returns one of the following error values:

LINEERR_INVALAGENTSTATE, LINEERR_INVALLINEHANDLE, LINEERR_INVALPARAM, LINEERR_NOMEM, LINEERR_OPERATIONFAILED, LINEERR_OPERATIONUNAVAIL, LINEERR_RESOURCEUNAVAIL, LINEERR_UNINITIALIZED.

Requirements

   
Target Platform Windows
Header tapi.h
Library Tapi32.lib
DLL Tapi32.dll

See also

About Call Center Controls

LINEPROXYREQUEST

LINE_PROXYREQUEST