Avaya CMS Change Skills from Excel VBA, Need to Kill Pop Ups

ninelivesguy

New Member
Joined
Jul 12, 2011
Messages
2
I have s spreadsheet where my team can enter skill changes per rep with a time stamp for implementation. It works very smoothly until it changes a skill for an agent on a call, then it gives 2 pop up confirmations from CMS, and VBA script pauses waiting for confirmation. This code below utilizes an existing connection from the main cms console:

Code:




Sub Skill(R As Integer)
Dim cvsApp As New ACSUP.cvsApplication
Dim cvsSrv As New ACSUPSRV.cvsServer
Dim AgMngObj As acsaa.cvsAgentMgmt
Dim Rep As String
Dim N As Integer
Dim S As Integer
Dim T As Integer
Dim sWarn As String
Set cvsSrv = cvsApp.Servers(1)
Set AgMngObj = cvsSrv.AgentMgmt
Rep = Range("B" & R)
N = Fix(Range("E" & R & ":AA" & R).Cells.SpecialCells(xlCellTypeConstants).Count / 2)
T = 4
ReDim SetArr(N, 3)
For S = 1 To N
SetArr(S, 1) = Cells(R, T)
SetArr(S, 2) = Cells(R, T + 1)
SetArr(S, 3) = 0
T = T + 2
Next
On Error Resume Next
AgMngObj.AcdStartUp -1, "", cvsSrv.ServerKey, -1
AgMngObj.OleAgentSetSkill 2, Format(Rep, "0000000"), 1, 0, 0, 0, N, SetArr, sWarn
Set AgMngObj = Nothing
Err.Clear
Set cvsSrv = Nothing
Set cvsApp = Nothing
Range("AB" & R) = Now()
Application.Wait (Now + TimeValue("0:00:09"))
End Sub

</PRE>
 

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.
The confirmation boxes I see are the same ones I would get if I were doing the manually while agent is on a call:

Request pending until agents in AUX or AVAIL state.

and

The script for Change Agent Skills has completed.

But no message at all if they are not on a call.
 
Upvote 0
Hi ninelivesguy,

My guess is that you are "piggybacking" the server connection already created by your CMS GUI. That is what I assume anyway since you are not creating a new instance of cvsServer.

The create server method is defined as:
Function CreateServer(sUserName As String, sPassword As String, vNewPassword, sServer As String, bInteractive As Boolean, sLanguage As String, oServer, [oConnection]) As Boolean

The problem, I THINK, is that the application creates a server instance with the bInteractive argument set to True. If this is the problem, then in order to suppress the messages you are receiving you would have to create a new server instance with bInteractive set to False:

Set cvsApp = CreateObject("ACSUP.cvsApplication")
Set cvsConn = CreateObject("ACSCN.cvsConnection")
Set cvsSrv = CreateObject("ACSUPSRV.cvsServer")

cvsApp.CreateServer(Username, Password, "", AvayaIP, False, "ENU", cvsSrv, cvsConn)
cvsConn.Login(Username, Password, AvayaIP, "ENU")


Also, somewhere in your switch you'll have to enable at least two instances per each applicable user id if you intend to have CMS open at the same time as this spreadsheet, otherwise your connection attempts will be refused.
 
Last edited:
Upvote 0

Forum statistics

Threads
1,224,503
Messages
6,179,134
Members
452,890
Latest member
Nikhil Ramesh

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top