Exploring, predicting and reporting with SAS Visual Analytics and SAS Visual Statistics

SAS VA Excel add-in: how to disable report error warning / auto continue to open report

Reply
New Contributor
Posts: 2

SAS VA Excel add-in: how to disable report error warning / auto continue to open report

All,

 

I am using a VBA code in Excel to refresh a SAS VA report, which is generated via SAS VA add-in version 7.1.

 

However, a pop-up saying "errors occurred downloading the Visual Analytics report that may prevent the entire report from being displayed".

 

How can the report be opened automatically each time, regardless of errors? (i.e. without need for user to click on "continue" each time)

 

Thank you!


SAS_VA_error.jpg
SAS Employee
Posts: 18

Re: SAS VA Excel add-in: how to disable report error warning / auto continue to open report

Hi,

 

The SAS Add-in for Microsoft Office will not suppress the error messages it generates. We want to alert you to the problem that exists in the SAS Visual Analytics report to explain why it may not display as expected in the SAS Add-in client.

 

Having said that, you *may* be able to control this in your VBA by using Application.DisplayAlerts=False. See this Microsoft article: https://msdn.microsoft.com/en-us/library/office/ff839782.aspx

 

 

 

New Contributor
Posts: 2

Re: SAS VA Excel add-in: how to disable report error warning / auto continue to open report

Posted in reply to fifthand57th

Many thanks for writing back.

 

Regarding "Application.DisplayAlerts = False", am afraid it would not work in this case as we need to allow other SAS add-in pop-ups (i.e. database connection, loading report status, etc.)

 

Goal here is to automate the production of SAS reports via the Excel add-in. Note that  issues are expected and we always want to ignore them and continue to produce the report. This will only be possible if we can disable that particular pop-up "errors downloading the report" or find a way to bypass it, automatically click "continue", etc.

 

Cheers.

SAS Employee
Posts: 18

Re: SAS VA Excel add-in: how to disable report error warning / auto continue to open report

Suggestion:

 

Sub InsertReport2GFromSASFolder()

    Dim sas As SASExcelAddIn
    Set sas = Application.COMAddIns.Item("SAS.ExcelAddIn").Object

 

    Application.DisplayAlerts = False 


    Dim report As SASReport2G
    Set report = sas.InsertReport2GFromSasFolder("/Shared Data/VA Reports/", Sheet1.Range("A1"))
   

   Application.DisplayAlerts = True


End Sub

 

New Contributor
Posts: 2

Re: SAS VA Excel add-in: how to disable report error warning / auto continue to open report

Posted in reply to fifthand57th

Many thanks once again for the follow-up.

 

Unfortunately, using "Application.displayalerts=false" also prevents SAS add-in dialogs from running (e.g. "running analytics" on a report, "opening report", and other alerts). Preventing these dialogs seems to prevent the report from being processed...

 

If there are any ways to specifically force the "errors downloading report" dialog box to select "continue", it will be the way to automate this report.

 

Cheers.

SAS Employee
Posts: 18

Re: SAS VA Excel add-in: how to disable report error warning / auto continue to open report

I checked with development. The default selection for that dialog box is Postpone not Continue. Using Application.DisplayAlerts=False is the same as clicking Postpone and would not allow the VA report to load with errors. 

Ask a Question
Discussion stats
  • 5 replies
  • 590 views
  • 0 likes
  • 2 in conversation