Fritz Paul
asked on
Why does my Access VBA code not stop at breakpoint
If the form has no records, the OnCurrent event will not fire.
/gustav
/gustav
In the VBA editor, click tools, options.
On the general tab, make sure your set for "Break on Unhandled Errors".
/Decompile is what will probably straighten it out though.
Jim.
On the general tab, make sure your set for "Break on Unhandled Errors".
/Decompile is what will probably straighten it out though.
Jim.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks, that worked. You guys are great!
1. Compact the application
2. Compile the application. From the VBA Editor window click Debug - Compile. Fix any errors, and continue doing this until the Compile menuitem is disabled.
3. Compact again
You may also need to decompile. To do that, create a shortcut with this as the Target:
"full path to msaccess.exe" /decompile
Run that shortcut, and select your database when Access opens. Access will decompile your code and leave your database open. After your database is open, run the 3 steps above again.
You may also have container corruption. If so, often the only fix is to create a new, blank database and import everything from the old database into the new one. If you have a corrupt object, however, this may not work, as Access will choke on the import of the corrupt object. If that occurs, then you must import each object individually, and recreate the corrupt object from a recent backup, or from scratch.
Finally, be sure that your Office and Windows installations are fully up to date.