Results 1 to 3 of 3
  1. #1
    kman42 is offline Advanced Beginner
    Windows XP Access 2007
    Join Date
    Mar 2011
    Posts
    40

    Database cannot be opened because the VBA project contained in it cannot be read

    I made a bunch of changes to my database yesterday and when I came back to it today, it crashed and I started getting this error when trying to open it:

    The database cannot be opened because the VBA project contained in it cannot be read. The database can be opened only if the VBA project is first deleted.

    Obviously, I don't want to delete my VBA project.

    I tried using the decompile command line utility, but I get the above error as soon as Access opens so the utility never runs. I also tried the compact and repair utility, but that didn't work either.

    I wouldn't mind going back to my backup from Friday, but I would like to be able to see my VBA code so I'm not working from scratch. Is there any way to view the code outside of Access? Can I open the .accdb file and view the code in a text editor or something?



    Any other suggestions?

  2. #2
    kennejd is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Mar 2011
    Posts
    188
    You could try creating a new Access database and importing the vba module.

  3. #3
    ajetrumpet is offline VIP
    Windows Vista Access 2007
    Join Date
    Mar 2010
    Location
    N/A
    Posts
    2,694
    Quote Originally Posted by kennejd View Post
    You could try creating a new Access database and importing the vba module.
    which is similar to the way this gentleman ended up solving it: http://www.access-programmers.co.uk/...d.php?t=174652

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

Similar Threads

  1. Replies: 3
    Last Post: 12-09-2010, 11:50 AM
  2. can a access database table be read-only?
    By princess-1 in forum Access
    Replies: 5
    Last Post: 10-24-2010, 07:52 PM
  3. Code needed when Database is Opened
    By Access_Headaches in forum Access
    Replies: 7
    Last Post: 08-13-2010, 01:03 PM
  4. Replies: 0
    Last Post: 10-13-2009, 11:54 AM
  5. Read only Access Database
    By Rameez in forum Access
    Replies: 7
    Last Post: 06-23-2009, 12:30 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