Results 1 to 4 of 4
  1. #1
    PicoTTS is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Jan 2016
    Posts
    29

    Inconsistent State - All VBA Missing

    Hi,



    I am having a huge issue where my access file seems to have been corrupted. When I try to open the file I get the following message:

    "Microsoft Access has detected that this database is in an inconsistent state and will attempt to recover the database......"

    After access recovers the file, all the tables, queries, forms, etc. are there but all the VBA I had is gone. I have tried to import them into a brand new database but it still comes up empty. I stupidly did not make a backup and need a way to retrieve the VBA code in the corrupted file. I don't really care about the data in the tables but I need to VBA. Any ideas?

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,525
    It is dead. I hope you have backups.
    ( i backup daily)

  3. #3
    ssanfu is offline Master of Nothing
    Windows XP Access 2010 32bit
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    Looks like you have learned The Three Rules of Computing like I did - the hard way!

    The Three Rules of Computing
    #1) - Backup
    #2) - Backup
    and
    .
    #3) BACKUP!!



    Many years ago, I had typed for over 3 hours without saving or creating a backup.
    Just one small static spark scrambled the memory (no hardware damage!) and ALL of the code was gone. (My Apple II+)
    Ever since, I save after each change and frequently close out of Access and make a backup every 10 to 15 minutes (depending on how much I have added/changed the code/forms/reports).


    Unfortunately, if you do not have any backups, you will have to re-create the VBA........

  4. #4
    CJ_London is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,430
    I don't really care about the data in the tables
    this also sounds like a potential contributory factor. If the tables get corrupted, you can lose the whole thing. Better to split the db and halve the risk. Only thing you might be able to do is create a new db and import each object from the original db (not the backup created by Access) one by one, ensuring you make a copy before the next import - One or more will fail in which case revert to the latest 'clean' copy, skip that object and carry on with the next one. All failed objects will need to be recreated manually. Or the db is so badly corrupted and you won't even be able to open it to copy objects.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 11
    Last Post: 06-04-2014, 10:58 AM
  2. Inconsistent results.. please help!
    By vikghai in forum Access
    Replies: 6
    Last Post: 02-09-2014, 05:37 PM
  3. Inconsistent Code Execution
    By Paul H in forum Forms
    Replies: 2
    Last Post: 09-19-2011, 10:06 AM
  4. Inconsistent??
    By bginhb in forum Programming
    Replies: 3
    Last Post: 09-07-2011, 03:10 PM
  5. Inconsistent Query Error...
    By DHavokD in forum Queries
    Replies: 8
    Last Post: 06-11-2009, 09:58 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums