'Run Macros from VBS
Function callMacro(strFilePath)
Set XLApp = CreateObject("Excel.Application")
XLApp.Application.DisplayAlerts = False
Set XLBook = XLApp.Workbooks.Open(strFilePath, readOnly=False)
XLBook.Sheets("Sheet1").Activate
'call Excel macro
XLApp.run "Macro1"
XLBook.Save
XLApp.Quit
Set XLBook = nothing
Set XLApp = nothing
End Function
2 comments:
It's working great! Thanks
replica bags blog replica nappy bags replica bags los angeles
Post a Comment