locked
Problems with Access 2003 DB when opened in Access 2010 RRS feed

  • Question

  • I have an Access 2003 database that was running fine when opened in Access 2010 for a few months.  Now, for some reason, I'm getting an oddball error popping up when clicking on a command button on any given form.  Once a button is clicked an error dialog pops up an reads 'error accessing file'.  When you click on the OK button you're taken immediately to the VBA module with the name of the routine highlighted.  There is another error message that pops up also, reading 'network connection may have been lost'.  Either way there is a disconnect between Access and the VBA piece.  Not sure why this is happening, but I'd assume the database has become corrupt.  Any ideas of what's going on?  Let me know if you need more info.

    Stan Benner

    Tuesday, May 29, 2012 12:37 PM

Answers

  • I have an Access 2003 database that was running fine when opened in Access 2010 for a few months.  Now, for some reason, I'm getting an oddball error popping up when clicking on a command button on any given form.  Once a button is clicked an error dialog pops up an reads 'error accessing file'.  When you click on the OK button you're taken immediately to the VBA module with the name of the routine highlighted.  There is another error message that pops up also, reading 'network connection may have been lost'.  Either way there is a disconnect between Access and the VBA piece.  Not sure why this is happening, but I'd assume the database has become corrupt.  Any ideas of what's going on?  Let me know if you need more info.

    Are you getting the error when you run it in Access 2010, or when you run it in Access 2003?  If the latter, try the following:

    First, make a backup copy of the database, in case we damage it more while trying to fix it.

    Create a "decompile 2003" shortcut on your desktop, with this as the command line to be executed:

        "C:\Program Files\Microsoft Office\OFFICE11\MSACCESS.EXE" /decompile

    If that's not the path to where Access 2003 is installed on your system, modify it as needed.

    In the Advanced settings for that shortcut, check the "Run As Administrator" box. 

    Having set up this adminstrator-mode decompile shortcut, double-click it to start Access.

    In that Access session, open your database while holding down the Shift key.  If you still get the error, this approach isn't going to help, and you can quit now.  Otherwise, proceed with the next steps.

    If the database opens, Compact and Repair the database.

    Open the database again, press Alt+F11 to switch to the VB Editor, and click Debug -> Compile (your project).  If any errors appear, fix them and recompile.

    Close the VB Editor.  Compact & Repair again.

    See if the problem has disappeared.


    Dirk Goldgar, MS Access MVP
    Access tips: www.datagnostics.com/tips.html

    • Marked as answer by Dummy yoyo Thursday, June 7, 2012 5:13 AM
    Tuesday, May 29, 2012 1:16 PM