Gates Is Antichrist
Well-known Member
- Joined
- Aug 15, 2002
- Messages
- 1,961
I would like a quick way to put a breakpoint on every routine in every code object. The desire is to have something better than
F9
Ctrl-Down arrow
up-arrow
F9
etc.
Obviously I'm one of those that uses the keyboard heavily to get things done fast. This is pretty good, though doing it rapidly by rote is fouled by some comment lines. But even this still suffers from having to locate other modules, worksheet code. form code, etc. (footnote **)
Can this be automated by some personal macro code routine, keystroke macros, or external process? Keep in mind that all of this must happen in a VBA window, severely limiting what you can do.
For perspective, sometimes we inherit massive workbooks with tons and tons of sheets and code. My desire is to learn/debug an app. by putting breakpoints on all possible code so I can see exactly what happens (and EVERYTHING that happens) when I do some action in the workbook. (And yes, I realize that no matter what, I'll still miss the File_Open unless I start the thing with shift-open, or insert a STOP statement and reopen.)
TIA
------------------------------------------------------------------------
** I do have a trick for finding every module(et al) that has code, which is close to if not foolproof. It is essentially this:
Ctrl-F for the letter u with alt-c ("search entire project")
Ctrl-End
F3
repeat until all modules found
Anyone see a flaw here? This catches every "Sub" and "Function" but I wonder if there's any other CODE it might miss, such as in a .CLS --- or in a "completely" external routine.
F9
Ctrl-Down arrow
up-arrow
F9
etc.
Obviously I'm one of those that uses the keyboard heavily to get things done fast. This is pretty good, though doing it rapidly by rote is fouled by some comment lines. But even this still suffers from having to locate other modules, worksheet code. form code, etc. (footnote **)
Can this be automated by some personal macro code routine, keystroke macros, or external process? Keep in mind that all of this must happen in a VBA window, severely limiting what you can do.
For perspective, sometimes we inherit massive workbooks with tons and tons of sheets and code. My desire is to learn/debug an app. by putting breakpoints on all possible code so I can see exactly what happens (and EVERYTHING that happens) when I do some action in the workbook. (And yes, I realize that no matter what, I'll still miss the File_Open unless I start the thing with shift-open, or insert a STOP statement and reopen.)
TIA
------------------------------------------------------------------------
** I do have a trick for finding every module(et al) that has code, which is close to if not foolproof. It is essentially this:
Ctrl-F for the letter u with alt-c ("search entire project")
Ctrl-End
F3
repeat until all modules found
Anyone see a flaw here? This catches every "Sub" and "Function" but I wonder if there's any other CODE it might miss, such as in a .CLS --- or in a "completely" external routine.