为什么我的CMS Autoscript出现“语句的预期结尾”错误?

时间:2019-09-26 18:53:58

标签: vbscript avaya

我正在尝试使用CMS Supervisor创建一个自动脚本,该脚本将自动创建我需要的报告。我遇到的问题是尝试自动将报告另存为文本文件。

我从另一个论坛帖子中找到了一行,并试图包含它,但是现在它给了我错误。

Microsoft VBScript compilation error
[Line: 64] Expected end of statement

我不是编码或VBscript专家,所以我不确定为什么会发生此错误。我怎么会收到此错误,该如何解决?

'LANGUAGE=ENU
'SERVERNAME=CMS-CCU-V18-Primary
Public Sub Main()

'## cvs_cmd_begin
'## ID = 2001
'## Description = "Report: Historical: Agent: Group AUX Daily: Print"
'## Parameters.Add "Report: Historical: Agent: Group AUX Daily: Print","_Desc"
'## Parameters.Add "Reports","_Catalog"
'## Parameters.Add "5","_Action"
'## Parameters.Add "1","_Quit"
'## Parameters.Add "Historical\Agent\Group AUX Daily","_Report"
'## Parameters.Add "7","_ACD"
'## Parameters.Add "1068","_Top"
'## Parameters.Add "5424","_Left"
'## Parameters.Add "13992","_Width"
'## Parameters.Add "11364","_Height"
'## Parameters.Add "default","_TimeZone"
'## Parameters.Add "The report Historical\Agent\Group AUX Daily was not found on ACD 7.","_ReportNotFound"
'## Parameters.Add "*","_BeginProperties"
'## Parameters.Add "PGHF Fraud","Agent Group"
'## Parameters.Add "-1","Date"
'## Parameters.Add "*","_EndProperties"
'## Parameters.Add "*","_BeginViews"
'## Parameters.Add "G1,0,0;0,2,0","data"
'## Parameters.Add "*","_EndViews"

   On Error Resume Next

   cvsSrv.Reports.ACD = 7
   Set Info = cvsSrv.Reports.Reports("Historical\Agent\Group AUX Daily")

   If Info Is Nothing Then
      If cvsSrv.Interactive Then
          MsgBox "The report Historical\Agent\Group AUX Daily was not found on ACD 7.", vbCritical Or vbOKOnly, "Avaya CMS Supervisor"
      Else
          Set Log = CreateObject("ACSERR.cvsLog") 
          Log.AutoLogWrite "The report Historical\Agent\Group AUX Daily was not found on ACD 7."
          Set Log = Nothing
      End If
   Else

       b = cvsSrv.Reports.CreateReport(Info,Rep)
       If b Then

          Rep.Window.Top = 1068
          Rep.Window.Left = 5424
          Rep.Window.Width = 13992
          Rep.Window.Height = 11364        


                        Rep.TimeZone = "default"



          Rep.SetProperty "Agent Group","PGHF Fraud"

          Rep.SetProperty "Date","-1"


          Rep.ReportView.Add "G1,0,0;0,2,0","data"



          b = Rep.ExportData("C:\Users\jlmar19\Desktop\GroupAUXDaily "&FormatDateTime(date()-1, 1)&".txt"), 44, 1, True, True, True)





          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

0 个答案:

没有答案
相关问题