ITAgent::CreateSessionWithPIN method (tapi3.h)

The CreateSessionWithPIN method creates a new agent session for the input ACD group and address, with Personal Identification Number (PIN).

Syntax

HRESULT CreateSessionWithPIN(
  [in]  ITACDGroup     *pACDGroup,
  [in]  ITAddress      *pAddress,
  [in]  BSTR           pPIN,
  [out] ITAgentSession **ppAgentSession
);

Parameters

[in] pACDGroup

Pointer to ITACDGroup interface.

[in] pAddress

Pointer to ITAddress interface for object available for receiving ACD calls.

[in] pPIN

Pointer to a BSTR representation of agent's PIN.

[out] ppAgentSession

Pointer to session created.

Return value

This method can return one of these values.

Value Meaning
S_OK
Method succeeded.
TAPI_E_CALLCENTER_NO_AGENT_ID
Agent not created by CreateAgentWithID.
TAPI_E_TIMEOUT
The operation failed because the TAPI 3 DLL timed it out. The timeout interval is two minutes.
E_INVALIDARG
pPIN is NULL.
E_POINTER
The pPIN or ppAgentSession parameter is not a valid pointer.
E_OUTOFMEMORY
Insufficient memory exists to perform the operation.

Remarks

The application must use SysAllocString to allocate memory for pPIN and use SysFreeString to free the memory when the variable is no longer needed.

TAPI calls the AddRef method on the ITAgentSession interface returned by ITAgent::CreateSessionWithPIN. The application must call Release on the ITAgentSession interface to free resources associated with it.

Requirements

   
Target Platform Windows
Header tapi3.h (include Tapi3.h)
Library Uuid.lib
DLL Tapi3.dll

See also

ITAgent

ITAgent::CreateSession

ITAgentSession