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!
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
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.
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
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.
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.
Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
Register now!
See how to use one filter for multiple data sources by mapping your data from SAS’ Alexandria McCall.
Find more tutorials on the SAS Users YouTube channel.