I'm trying to run a vbscript file from excel macro, can anyone please help.
Dim sFilename As String
sFilename = ActiveWorkbook.Path & "C:\Users\266720\AppData\Roaming\SAP\SAP GUI\Scripts\Script7-pa30.vbs"
sFilename.Run
Could be an issue with the space in your reference.
"C:\Users\266720\AppData\Roaming\SAP\SAP GUI\Scripts\Script7-pa30.vbs"
I would change the folder name to SAP_GUI and see how that works, or use double quotes around the whole line.
"""C:\Users\266720\AppData\Roaming\SAP\SAP GUI" & "\Scripts\Script7-pa30.vbs"""
c:\foo\bar\c:\Users\266...You are concatening two absolute paths