I have created a macro group that needs to be run every evening after our data wharehouse has been updated so that it will update all of our reports and queries before we come in to the office in the am. How do I schedule this macro to run at a certain time in the evening every night? I have tried to use task schedule with the following code. Schedule a VBA macro to run at a specific time User Name. I think you need to use Windows task scheduler to run the workbook at a specified interval. I set up a scheduled task on a server to run an Access macro that outputs a file. When I set the task to “run only when user is logged on” it runs perfectly. When I change it to “run whether user is logged on or not” it fails.
Using Task Scheduler

Task Scheduler Microsoft Windows
Currently I have a task setup which opens my workbook every day at a set time, runs 2 macros in the workbook open procedure and then closes excel.
However as the macros email people, having the code run on the workbook open procedure is not ideal. If the file is opened at any other time these emails will still be sent, which will just confuse people (it also makes it a pain to edit as the procedure closes the workbook.)
Is there a way to use the task scheduler to run specific Macros so I wouldn't have to have them in the workbook open procedure?