Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
halt macro execution, inspect progress and then resume execution
I would like to halt the execution of a complex macro at a specific
location in the code and then navigate around several worksheets (maybe even look at some different workbooks) and after I'm done inspecting I would like to resume the macro execution at the same point where it was halted. What is the recommended method for doing something like this? |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
halt macro execution, inspect progress and then resume execution
"John" wrote:
I would like to halt the execution of a complex macro at a specific location in the code and then navigate around several worksheets (maybe even look at some different workbooks) and after I'm done inspecting I would like to resume the macro execution at the same point where it was halted. What is the recommended method for doing something like this? You can sprinkle Stop statements at key junctures in your macros. Alternatively, you can set breakpoints by pressing F9 with the cursor hovering over a statement. You can also use F8 step through the code and ctrl+F8 to run to the statement where the cursor is hovering. If your macros loops, you can pause execution randomly by pressing ctrl+alt+Pause (on my computer). Alternatively, you might at logic to execute the Stop statement when a certain condition is met, for example when an iteration counter is a specific value. Press F5 when you are ready to resume execution. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Speeding up execution of a Macro | Excel Programming | |||
Macro Execution | Excel Discussion (Misc queries) | |||
Halt Macro Execution | Excel Programming | |||
Progress Meter during macro execution | Excel Programming |