PDA

View Full Version : Solved: Stepping through Userform VBA code



simora
04-26-2013, 02:44 PM
Is there a way to watch vba userform code execute line by line.
I want to be able to step through code to see exactly where or how its failing.
How can I do this? F8 DOES NOT WORK for this.

gmaxey
04-26-2013, 04:32 PM
Put a stop statement in your code.

Some code
Stop
Some more code

Let it run to the stop and then press the F8 key.

Note some actions like creating a new document etc. will often let things run on so be sure to add Stop or breaks after these events.

simora
04-26-2013, 08:16 PM
gmaxey:

Thanks ! It works.