Jon has attended:
Excel VBA Introduction course
Excel VBA Intermediate course
Effective Communication Skills course
Power BI Modelling, Visualisation and Publishing course
Scheduling VBA Macros to Run
Hi,
Is there a way to schedule VBA code (currently held in Excel) to run daily at a set time?
Ideally I would not leave my computer on in order to run the code, so it should run at network level (as opposed to locally).
Many thanks,
Jon
RE: Scheduling VBA Macros to Run
Hi Jon,
Thank you for the forum question.
VBA can only be executed from Excel and the file need to be open. If the code is stored in the template of Excel you do not need a special file to be open, but Excel need to be running.
The code:
Application.ontime timevalue("15:30:00"), "runmacro"
Will execute a macro called runmacro 15:30.
Kind regards
Jens Bonde
Microsoft Office Specialist Trainer
Tel: 0207 987 3777
STL - https://www.stl-training.co.uk
98%+ recommend us
London's leader with UK wide delivery in Microsoft Office training and management training to global brands, FTSE 100, SME's and the public sector
RE: Scheduling VBA Macros to Run
Thanks Jens,
Is there any way to make it work through the Windows Task Scheduler?
Thanks,
Jon
RE: Scheduling VBA Macros to Run
Hi Jon,
Unfortunately I have no knowledge of the Windows Task Scheduler, but I found the link below, which can help you in the right direction.
https://stackoverflow.com/questions/22771185/how-to-set-recurring-schedule-for-xlsm-file-using-windows-task-scheduler
Kind regards
Jens Bonde
Microsoft Office Specialist Trainer
Tel: 0207 987 3777
STL - https://www.stl-training.co.uk
98%+ recommend us
London's leader with UK wide delivery in Microsoft Office training and management training to global brands, FTSE 100, SME's and the public sector