I have a SAS Code where inside we have embedded the VB script, While trying to execute the code through sas application i am getting an error stating like subscript out of an error, at the following block of code
With oExcel
.Sheets(1).ListObjects.Add 1, .Sheets(1).Range(sRange), , , "Tableau1"
.Sheets(1).ListObjects("Tableau1").TableStyle = "TableStyleLight2"
.Sheets.Add .Sheets(1)
.Sheets(1).Range("B1").VerticalAlignment = -4160
Set ZGPPict = .Sheets(1).Range("B2").Worksheet.Pictures.Insert(ZGPPicture)
For iRowAdd = 1 To 6
.Sheets(1).Rows("1").EntireRow.Insert
Next
We tried applying the solutions but it doesn;t work