cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
46
Views
0
Helpful
0
Comments
cdnadmin
Level 11
Level 11
This document was generated from CDN thread

Created by: Hanspeter Widmer on 23-06-2008 12:58:31 PM
Hello,

If I due a dump on the event change OnSetAgentModeEvent Event details: Arguments contains 77 Args

…….
LastError:1)

…….
SavedLoginInfo)

…….
StatusSystemStatusCTIServer:1 StatusCtiServerDriver:1 StatusCentralController:1 StatusPeripherals5000:1 5001:1 5003:0 5015:0))

…….

we have on the LastError a substructure (IDispatch) who contains N elements. Wihle the “(….)” describes a collection of elements.

But when you look on the collection of LastError, you will see one element with value ‘’ = empty/blank and the value = 1.

My question is now how theLastError structure is build by design…or pointer to related documentation

Thank you

Hp

Subject: Re: Structure of LastError & substructure (IDispatch)
Replied by: David Lender on 23-06-2008 04:05:55 PM
This is a CTIOS Cil question not a CTI Server protocol question.

Further information on this can be found in the CTIOS Developer's Guide.
Last error is an Integer per the Session properties in table 8-1.

if you require further assistance you will need open a Service Request for Developer Serivices and provide detailed logs and code snippets.

Subject: Re: Structure of LastError & substructure (IDispatch)
Replied by: Hanspeter Widmer on 24-06-2008 11:01:05 AM
Hi Again,

Further information on this can be found in the CTIOS Developer's Guide.
Last error is an Integer per the Session properties in table 8-1.

OK, here it is documentet as an integer!

Using your Exercice3.exe at the event:

You can Login now!

Requesting SetAgent

OnSetAgentMode Event received
Arguments contains 73 Args
............................................

InternalCallsRcvdTimeToday:0
InternalCallsRcvdSession:0
ClientAgentTemporaryID:agent.1214304569
ClassIdentifier:1
IsSupervisor:0
LastError:1) <<<<<<<<<<< NOT INTEGER!
...........................................

the last error comes as LastError:1) as an OLE IDispatch in other words as
an Array type. Also the first member has no Key name only the first element of
the array is an Integer with value "1".

If it is only an Integer LasterError would like this LastError:1 what is different to the
real OnSetAgentMode event.

I hope the difference is now clear enough ?

Hp

Edited by: Hanspeter Widmer on Jun 24, 2008 7:02 AM

Subject: Re: Structure of LastError & substructure (IDispatch)
Replied by: David Lender on 24-06-2008 02:58:28 PM
LastError is an arguments array with key ""

To obtain the value

private void m_session_OnSetAgentModeEvent(Cisco.CTIOSCLIENTLib.Arguments pIArguments) {
LogEvent("OnSetAgentModeEvent", pIArguments);
// Pack up the arguments and perform an agent login
Cisco.CTIOSCLIENTLib.Arguments m_Args = new Cisco.CTIOSCLIENTLib.Arguments();
int nRetVal;
Cisco.CTIOSCLIENTLib.Arguments m_LEArgs = new Cisco.CTIOSCLIENTLib.Arguments();
Cisco.CTIOSARGUMENTSLib.Arg m_LEArg = new Cisco.CTIOSARGUMENTSLib.Arg();
string s;
int i;
s = pIArguments.GetValueString("AgentID");
m_LEArg = pIArguments.GetValue("LastError");
i = m_LEArg.GetType;
if ((i == Cisco.CTIOSARGUMENTSLib.enumArgTypes.ARG_ARGARRAY)) {
m_LEArgs = m_LEArg.GetValueArray;
}
i = m_LEArgs.GetValueInt("");
Log(("Last Error is " + i.ToString));
m_Args.AddItem("Agentid", agentid.Text);
m_Args.AddItem("AgentPassword", agentpw.Text);
m_Args.AddItem("AgentInstrument", instrument.Text);
m_Args.AddItem("PeripheralID", peripheralid.Text);
// send login request
nRetVal = m_Agent.Login(m_Args);
Log(("Login returns("
+ (Str(nRetVal) + ")")));
m_Args = null;
m_LEArgs = null;
}

Generates:

OnSetAgentModeEvent Event received
Arguments contains 80 Args
PeripheralID:5000
PeripheralType:0
AgentState:eUnknown
AvailTimeToday:0
LoggedOnTimeToday:0
NotReadyTimeToday:0
AgentOutCallsToday:0
AgentOutCallsTalkTimeToday:0
AgentOutCallsTimeToday:0
AgentOutCallsHeldToday:0
AgentOutCallsHeldTimeToday:0
HandledCallsToday:0
HandledCallsTalkTimeToday:0
HandledCallsTimeToday:0
IncomingCallsHeldToday:0
IncomingCallsHeldTimeToday:0
InternalCallsHeldToday:0
InternalCallsHeldTimeToday:0
AvailTimeSession:0
LoggedOnTimeSession:0
NotReadyTimeSession:0
AgentOutCallsSession:0
AgentOutCallsTalkTimeSession:0
AgentOutCallsTimeSession:0
AgentOutCallsHeldSession:0
AgentOutCallsHeldTimeSession:0
HandledCallsSession:0
HandledCallsTalkTimeSession:0
HandledCallsTimeSession:0
IncomingCallsHeldSession:0
IncomingCallsHeldTimeSession:0
InternalCallsSession:0
InternalCallsTimeSession:0
InternalCallsRcvdTimeSession:0
InternalCallsHeldSession:0
InternalCallsHeldTimeSession:0
InternalCallsToday:0
InternalCallsTimeToday:0
HandledCallsAfterCallTimeSession:0
HandledCallsAfterCallTimeToday:0
MRDID:0
ICMAgentID:0
AgentMode:2
MaxTaskLimit:0
NumTasks:0
AgentExtensionnull)
AgentID:5000
AgentInstrumentnull)
SkillGroups)
UniqueObjectID:agent.5000.5000
MessageID:eSetAgentModeEvent
InternalCallsRcvdToday:0
InternalCallsRcvdTimeToday:0
InternalCallsRcvdSession:0
ClientAgentTemporaryID:agent.1214318916
ClassIdentifier:1
IsSupervisor:0
LastError:1)
ConnectionMode:1
Filter:filtertarget = agent.5000.5000
CILConnectionID:12
AutoLogin:0
SavedAgentState:9
WaitingforRecovery:0
SavedLoginInfo)
StatusSystemStatusCTIServer:1 StatusCtiServerDriver:1 StatusCentralController:1 StatusPeripherals5000:1))
CurrentProfile:Main Contact Center
LoginTime:0
IsAgentTeamMember:0
AgentAvailabilityStatus:-1
ICMAvailableTimeSession:0
RoutableTimeToday:0
ICMAvailableTimeToday:0
RoutableTimeSession:0
OriginatingClientID:dlender-wxp-97684-98196
LoginNamenull)
BlockAllEvents:1
AgentCallMode:0
SilentMonitorTargetAgentUIDnull)
SilentMonitorCallUIDnull)

Last Error is 1
Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Quick Links