Welcome to the fracta.net forum!

Share your coding ideas or ask questions.

Question Excel Macro to Automate Skill/Level changes for Avaya CMS

  • botsblitz31
  • Visitor
  • Visitor
9 years 8 months ago #436 by botsblitz31
@Tyger0951,

Here's a sample of what the template looks like, the user will key in the skills with their priority horizontally and the template will skill the agents.



@Roller

I did try to set the SetArr thru the code manually and it did work, the code ran perfectly and skilled the acdid as it should, but I can't seem to figure out how to do this dynamically wherein the code will check each cell for skills and priority.

Nice catch there with the Skill being declared as string, I'll try to set it as integer and see what happens.

Please Log in or Create an account to join the conversation.

More
9 years 8 months ago - 9 years 8 months ago #437 by roller
Look I see few bits that need checking.

firstly Set AgMngObj = cvsSrv.AgentMgmt should be outside the loop that populate the array with values. You are setting it each time you add a skill.

In this line:

AgMngObj.OleAgentSetSkill 2, "1029968", 1, 0, 0, 0, 3, SetArr, ""

the number 3 just before the SetArr represents the number of skills being set, if you are more or less in your array that may cause a problem. The first 0 (after "68",1,0) represents the base skill, I am not sure if this needs to be set to a real skill.

Check these few things while you are there. good luck and let us know if you work it.

If none of this works I have an old file somewhere on my hard drive that has a GUI and designed to change skills for many agents, not all the same skills. I can try to find it and make it available for few bucks under the Products link.

I was just looking at my GUI Excel skill changer and I think I spotted the your error. You need to use ReDim Preserve not ReDim for the array. Any way I have a nice version that is ready if you guys are interested I will clean it up and upload it to the Shop for about $5.
Last edit: 9 years 8 months ago by roller.

Please Log in or Create an account to join the conversation.

  • botsblitz31
  • Visitor
  • Visitor
9 years 8 months ago #438 by botsblitz31
Thanks Roller, I'll make sure to check on these things i'll update you guys soon. Thanks for the help!

Please Log in or Create an account to join the conversation.

  • Tyger0951
  • Visitor
  • Visitor
9 years 8 months ago - 9 years 8 months ago #442 by Tyger0951
First off let me just say roller you've been amazing Thank You.

So I may be wrong but the avaya scripting only allows for at max 50 agents to be gated at once. I'm current gating very large groups upwards to 600. After each 50 agents Avaya has two prompts/pop up boxes , 1 being the list of the agents and 2 a msg box stating script completed, both needing to have OK clicked before the next set is ran.

So is there a way to stop the pop ups entirely kind of similar as if a acsup automatic avaya script was ran? Or maybe use sendkeys to send enter to those windows. Kind of stumped at the moment on this one. I've tried different variations of using the INTERACTIVE code that appears in recorded script such as
Code:
cvs.SRV.Interactive False
or using = False.

I'm assuming that since
Code:
'## Parameters.Add "True","_Interactive"
appears in scripts that it should be possible to set it but drawing a blank.


Code:
Sub GateAgent() Dim agents As String Dim cvsApp As Object Dim cvsConn As Object Dim cvsSrv As Object Dim SetArr() As Variant Dim sWarn As String Dim Skills() As Variant Application.DisplayAlerts = False ' Turns off excels alerts when gating takes long ReDim SetArr(3, 4) SetArr(1, 1) = 3 SetArr(1, 2) = 1 SetArr(1, 3) = 0 SetArr(1, 4) = 0 SetArr(2, 1) = 338 SetArr(2, 2) = 2 SetArr(2, 3) = 0 SetArr(2, 4) = 0 SetArr(3, 1) = 344 SetArr(3, 2) = 2 SetArr(3, 3) = 0 SetArr(3, 4) = 0 Set cvsApp = CreateObject("ACSUP.cvsApplication") Set cvsConn = CreateObject("ACSCN.cvsConnection") Set cvsSrv = cvsApp.Servers(1) ' Start Agent agents = Range("AgentList1").Value Set agMngObj = cvsSrv.AgentMgmt agMngObj.AcdStartUp -1, "", cvsSrv.ServerKey, -1 agMngObj.OleAgentSetSkill_R16_1 2, "" & agents & "", 1, 0, 0, 0, 3, SetArr, "" agents = Range("AgentList2").Value agMngObj.AcdStartUp -1, "", cvsSrv.ServerKey, -1 agMngObj.OleAgentSetSkill_R16_1 2, "" & agents & "", 1, 0, 0, 0, 3, SetArr, "" agents = Range("AgentList3").Value agMngObj.AcdStartUp -1, "", cvsSrv.ServerKey, -1 agMngObj.OleAgentSetSkill_R16_1 2, "" & agents & "", 1, 0, 0, 0, 3, SetArr, "" agents = Range("AgentList4").Value Set agMngObj = cvsSrv.AgentMgmt agMngObj.AcdStartUp -1, "", cvsSrv.ServerKey, -1 agMngObj.OleAgentSetSkill_R16_1 2, "" & agents & "", 1, 0, 0, 0, 3, SetArr, "" agents = Range("AgentList5").Value agMngObj.AcdStartUp -1, "", cvsSrv.ServerKey, -1 agMngObj.OleAgentSetSkill_R16_1 2, "" & agents & "", 1, 0, 0, 0, 3, SetArr, "" agents = Range("AgentList6").Value agMngObj.AcdStartUp -1, "", cvsSrv.ServerKey, -1 agMngObj.OleAgentSetSkill_R16_1 2, "" & agents & "", 1, 0, 0, 0, 3, SetArr, "" agents = Range("AgentList7").Value Set agMngObj = cvsSrv.AgentMgmt agMngObj.AcdStartUp -1, "", cvsSrv.ServerKey, -1 agMngObj.OleAgentSetSkill_R16_1 2, "" & agents & "", 1, 0, 0, 0, 3, SetArr, "" agents = Range("AgentList8").Value agMngObj.AcdStartUp -1, "", cvsSrv.ServerKey, -1 agMngObj.OleAgentSetSkill_R16_1 2, "" & agents & "", 1, 0, 0, 0, 3, SetArr, "" agents = Range("AgentList9").Value agMngObj.AcdStartUp -1, "", cvsSrv.ServerKey, -1 agMngObj.OleAgentSetSkill_R16_1 2, "" & agents & "", 1, 0, 0, 0, 3, SetArr, "" agents = Range("AgentList10").Value Set agMngObj = cvsSrv.AgentMgmt agMngObj.AcdStartUp -1, "", cvsSrv.ServerKey, -1 agMngObj.OleAgentSetSkill_R16_1 2, "" & agents & "", 1, 0, 0, 0, 3, SetArr, "" agents = Range("AgentList11").Value agMngObj.AcdStartUp -1, "", cvsSrv.ServerKey, -1 agMngObj.OleAgentSetSkill_R16_1 2, "" & agents & "", 1, 0, 0, 0, 3, SetArr, "" agents = Range("AgentList12").Value agMngObj.AcdStartUp -1, "", cvsSrv.ServerKey, -1 agMngObj.OleAgentSetSkill_R16_1 2, "" & agents & "", 1, 0, 0, 0, 3, SetArr, "" Application.DisplayAlerts = True Set agMngObj = Nothing Set cvsApp = Nothing Set cvsConn = Nothing Set cvsSrv = Nothing End Sub
Last edit: 9 years 8 months ago by Tyger0951.

Please Log in or Create an account to join the conversation.

More
9 years 8 months ago #443 by roller
The best way I know off to keep the application non interactive is by establishing a new server object rather than hooking into the running instance. There are examples at the beginning of this topic but the method to create a new server would start like this:

Sub OpenConn()
Const Username As String = "xxxxxx"
Const Password As String = "xxxxxxxxx"
Set cvsApp = CreateObject("ACSUP.cvsApplication")
Set cvsConn = CreateObject("ACSCN.cvsConnection")

Set cvsSrv = CreateObject("ACSUPSRV.cvsServer")
'Set cvsSrv = cvsApp.servers(1) not like this !!!
Set Rep = CreateObject("ACSREP.cvsReport")
If cvsApp.CreateServer(Username, "", "", "1xx.xxx.xxx.xxx", False, "ENU", cvsSrv, cvsConn) Then
If cvsConn.Login(Username, Password, "1xx..xxx.xxx.xxx", "ENU") Then
End If
End If

end sub

1xx..xxx.xxx.xxx is the server IP or name like cms.mycompany.com.


You have to provide a user name, password and the server name/IP. The FALSE is the below line is what makes it not interactive.

If cvsApp.CreateServer(Username, "", "", "1xx.xxx.xxx.xxx", False, "ENU",...

Hooking into the existing server object like this 'Set cvsSrv = cvsApp.Servers(1)' won't work. I tried to do what you did in the past but it never worked.

Just for an experiment set the server like I showed you above and see if the prompts still pop up.

Please Log in or Create an account to join the conversation.

Time to create page: 0.476 seconds
Powered by Kunena Forum