I know you can create scripts in CMS Supervisor but is there some way (VBA?) to have that script run a range of data for you?
Here is my script... What I want to do is have it read a list of agent ids from a txt file by changing the Rep.SetProperty values.
Any thoughts on this?
Thank you,
Ray
'LANGUAGE=ENU
'SERVERNAME=XXXX.XXXX.com
Public Sub Main()
'## cvs_cmd_begin
'## ID = 2001
'## Description = "Report: Historical: CMS custom: ACC AGENT REPORT: Print"
'## Parameters.Add "Report: Historical: CMS custom: ACC AGENT REPORT: Print","_Desc"
'## Parameters.Add "Reports","_Catalog"
'## Parameters.Add "5","_Action"
'## Parameters.Add "1","_Quit"
'## Parameters.Add "Historical\CMS custom\ACC AGENT REPORT","_Report"
'## Parameters.Add "1","_ACD"
'## Parameters.Add "4785","_Top"
'## Parameters.Add "780","_Left"
'## Parameters.Add "18465","_Width"
'## Parameters.Add "6885","_Height"
'## Parameters.Add "The report Historical\CMS custom\ACC AGENT REPORT was not found on ACD 1.","_ReportNotFound"
'## Parameters.Add "*","_BeginProperties"
'## Parameters.Add "8061","Agent"
'## Parameters.Add "05/01/04-05/31/04","Dates"
'## Parameters.Add "*","_EndProperties"
'## Parameters.Add "*","_BeginViews"
'## Parameters.Add "*","_EndViews"
On Error Resume Next
cvsSrv.Reports.ACD = 1
Set Info = cvsSrv.Reports.Reports("Historical\CMS custom\ACC AGENT REPORT")
If Info Is Nothing Then
If cvsSrv.Interactive Then
MsgBox "The report Historical\CMS custom\ACC AGENT REPORT was not found on ACD 1.", vbCritical Or vbOKOnly, "CentreVu Supervisor"
Else
Set Log = CreateObject("CVSERR.cvsLog")
Log.AutoLogWrite "The report Historical\CMS custom\ACC AGENT REPORT was not found on ACD 1."
Set Log = Nothing
End If
Else
b = cvsSrv.Reports.CreateReport(Info,Rep)
If b Then
Rep.Window.Top = 4785
Rep.Window.Left = 780
Rep.Window.Width = 18465
Rep.Window.Height = 6885
Rep.SetProperty "Agent","8061"
Rep.SetProperty "Dates","05/01/04-05/31/04"
b = Rep.PrintReport
Rep.Quit
If Not cvsSrv.Interactive Then cvsSrv.ActiveTasks.Remove Rep.TaskID
Set Rep = Nothing
End If
End If
Set Info = Nothing
'## cvs_cmd_end
End Sub
Here is my script... What I want to do is have it read a list of agent ids from a txt file by changing the Rep.SetProperty values.
Any thoughts on this?
Thank you,
Ray
'LANGUAGE=ENU
'SERVERNAME=XXXX.XXXX.com
Public Sub Main()
'## cvs_cmd_begin
'## ID = 2001
'## Description = "Report: Historical: CMS custom: ACC AGENT REPORT: Print"
'## Parameters.Add "Report: Historical: CMS custom: ACC AGENT REPORT: Print","_Desc"
'## Parameters.Add "Reports","_Catalog"
'## Parameters.Add "5","_Action"
'## Parameters.Add "1","_Quit"
'## Parameters.Add "Historical\CMS custom\ACC AGENT REPORT","_Report"
'## Parameters.Add "1","_ACD"
'## Parameters.Add "4785","_Top"
'## Parameters.Add "780","_Left"
'## Parameters.Add "18465","_Width"
'## Parameters.Add "6885","_Height"
'## Parameters.Add "The report Historical\CMS custom\ACC AGENT REPORT was not found on ACD 1.","_ReportNotFound"
'## Parameters.Add "*","_BeginProperties"
'## Parameters.Add "8061","Agent"
'## Parameters.Add "05/01/04-05/31/04","Dates"
'## Parameters.Add "*","_EndProperties"
'## Parameters.Add "*","_BeginViews"
'## Parameters.Add "*","_EndViews"
On Error Resume Next
cvsSrv.Reports.ACD = 1
Set Info = cvsSrv.Reports.Reports("Historical\CMS custom\ACC AGENT REPORT")
If Info Is Nothing Then
If cvsSrv.Interactive Then
MsgBox "The report Historical\CMS custom\ACC AGENT REPORT was not found on ACD 1.", vbCritical Or vbOKOnly, "CentreVu Supervisor"
Else
Set Log = CreateObject("CVSERR.cvsLog")
Log.AutoLogWrite "The report Historical\CMS custom\ACC AGENT REPORT was not found on ACD 1."
Set Log = Nothing
End If
Else
b = cvsSrv.Reports.CreateReport(Info,Rep)
If b Then
Rep.Window.Top = 4785
Rep.Window.Left = 780
Rep.Window.Width = 18465
Rep.Window.Height = 6885
Rep.SetProperty "Agent","8061"
Rep.SetProperty "Dates","05/01/04-05/31/04"
b = Rep.PrintReport
Rep.Quit
If Not cvsSrv.Interactive Then cvsSrv.ActiveTasks.Remove Rep.TaskID
Set Rep = Nothing
End If
End If
Set Info = Nothing
'## cvs_cmd_end
End Sub