BookmarkSubscribeRSS Feed
Nsp96
Calcite | Level 5

Hi,

I have a vba code to refresh sas programs like below, earlier the code executed without any error. Now i am facing "value cannot be null" error. Parameter:contentInfo" error. Any idea on this.

 

dim SAS as sasexceladdin

set SAS=application.comaddins.item("SASExceladdin").object

SAS.Refresh ("DATA")

SAS.Refresh (SASApp_WORK_Data)

 

Where "DATA" is my program imported in excel via addin.

 

kindly help!

1 REPLY 1
fifthand57th
SAS Employee

@Nsp96 

 

Double-check that you have enabled the SAS Add-in VBA reference. 

 

Does this work?

 

Sub test()
  Dim SAS As SASExcelAddIn
  Set SAS = Application.COMAddIns.Item("SAS.ExcelAddin").Object
  SAS.Refresh ThisWorkbook
End Sub