Better to use a vbs as you indicated
vbs
, which is a text file with a .vbs extension (see sample code below)vbs
vbs
to open the workbook
at the scheduled time and then either:
Private Sub Workbook_Open()
event in the ThisWorkbook
module to run code when the file is openedApplication.Run
in the vbs
to run the macroSee this example of the later approach at Running Excel on Windows Task Scheduler
sample vbs
Dim ObjExcel, ObjWB
Set ObjExcel = CreateObject("excel.application")
'vbs opens a file specified by the path below
Set ObjWB = ObjExcel.Workbooks.Open("C:\temp\rod.xlsm")
'either use the Workbook Open event (if macros are enabled), or Application.Run
ObjWB.Close False
ObjExcel.Quit
Set ObjExcel = Nothing