Windows 7 - Phantom break point in VBA module

Asked By NKTowe on 26-Nov-07 05:21 PM
Access 2003, stand-alone single-file .MDB (while developing).  If I open the
application and select a button on a form that causes some code in a module
to run, the application opens up the VBA window with a line of code
highlighted in yellow as if I had planted a breakpoint.  But I didn't.  There
is no diagnostic, and there is no red-button breakpoint on the left.  If I
press F5 the appliation continues just fine.  If I re-execute the thing, it
executes without the halt.  If I do a repair/compress it doesn't fix it.  If
I manually add a break point on the line, execute up to it, clear the break
point, save, exit to Windows, restart - phantom breakpoint returns.

I get clean compiles.

I finally got rid of it by cutting the subroutine to the clipboard, and then
pasted it back in at the end of the module.  Strange, yes?

I have observed this several times over the years.

Anybody have any idea as to the cause?




Robert Morley replied on 26-Nov-07 07:57 PM
This is quite common in several versions of Access.  Normally, setting a breakpoint and removing it again will work, but if not, you
can decompile your project, either using the /decompile switch or by adding a dummy reference and removing it again.  (Or, as you
discovered, cutting & pasting the routine.)


Rob