how do you execute single line of code?

H

honestlylion

i am troubleshooting some code i wrote, and it would be very helpful to
know the command for running the code line-by-line so i can identify my
error more quickly. thanks.
 
D

Doug Kanter

"honestlylion" <[email protected]>
wrote in message
i am troubleshooting some code i wrote, and it would be very helpful to
know the command for running the code line-by-line so i can identify my
error more quickly. thanks.

While in the code editor, click on Help, start the help system, and search
for the word "Step". That'll tell you how, assuming Excel uses the same
terminology as every other programming language on earth.
 
A

Andrew Taylor

Have a look at the Debug menu in the VBA window: it shows the
options and shortcuts, e.g. F8 to step through the code.
You can also make a line a Breakpoint (F9), which will make the
debugger stop when it reaches the line.
 
Top