Search code examples
ms-accessvbaautoexec

How to open an Access database that has an error on AutoExec?


I created an AutoExec macro on Access 2007 and wanted to try a new function I created on VBA, but the function throws an error and everytime I open the database I get an error and the database closes, so I can't edit the code or the AutoExec macro because the application closes right after ending the AutoExec.

Any idea how can I open the database without having to run the AutoExec?


Solution

  • Try opening the DB by holding down the SHIFT key until the DB is loaded. This will disable all macros before running. This way you can open the DB, correct the error and then try it again.