Debugging code in a form

  • Thread starter Thread starter Jim Pockmire
  • Start date Start date
You can just type the name of the sub and press enter.

Place a question mark and space in front if it is a function.

Or use Call, e.g.:
Call MyProc

This assumes that MyProc is a function in a standard module (i.e. not a
Private procedure, nor in the module of a form/report.)
 
Ah, but this code is in a form. Are there any options here, short of
starting the code through a button on the form?
 
If the procedure is called MyProc, and the form is named Form1, remove the
Private from the procedure declaration, and enter:
Call Form_Form1.MyProc

You will see the "Form_Form1" as the name of the module in the Title bar of
the VBA window.
 
Back
Top