Hello everyone,
I have a workbook with a macro that runs automatically when the file is opened. It works great, except that the process takes quite some time due to the size of the file and the scripts it triggers. I have Windows Scheduler setup to open (thus run) the worksheet at a certain time each day. Occasionally I need to do maintenance to the file and do not want it to automatically start running all of the time consuming scripts and functions.
The workbook is extremely large and takes a minute or two to load, and to make matters worse, I remote desktop to the computer... So, holding the shift button when opening isn't a good option. Also, since the macro triggers FTP downloads and other scripts, ESCing after the macro is not a great option either because I have to "chase" those processes down to stop them.
What I would like to do is have the macro ask a question, such as "Would you like to stop the macro? If no selection is made in 2 minutes, the macro will automatically proceed." If "yes" or "ok" or whatever is not selected, it will proceed, if it is selected, the macro will end and allow me to edit the workbook. In other words, when Windows Scheduler opens it, and I am not there to stop it, it will proceed as planned. If I manually open the file for maintenance, I have the option of stopping the macro before it triggers all of the external scripts.
Any ideas?
Thanks!
I have a workbook with a macro that runs automatically when the file is opened. It works great, except that the process takes quite some time due to the size of the file and the scripts it triggers. I have Windows Scheduler setup to open (thus run) the worksheet at a certain time each day. Occasionally I need to do maintenance to the file and do not want it to automatically start running all of the time consuming scripts and functions.
The workbook is extremely large and takes a minute or two to load, and to make matters worse, I remote desktop to the computer... So, holding the shift button when opening isn't a good option. Also, since the macro triggers FTP downloads and other scripts, ESCing after the macro is not a great option either because I have to "chase" those processes down to stop them.
What I would like to do is have the macro ask a question, such as "Would you like to stop the macro? If no selection is made in 2 minutes, the macro will automatically proceed." If "yes" or "ok" or whatever is not selected, it will proceed, if it is selected, the macro will end and allow me to edit the workbook. In other words, when Windows Scheduler opens it, and I am not there to stop it, it will proceed as planned. If I manually open the file for maintenance, I have the option of stopping the macro before it triggers all of the external scripts.
Any ideas?
Thanks!