VBA error on new computers.

mafhobb

Registered User.
Local time
Yesterday, 22:25
Joined
Feb 28, 2006
Messages
1,249
Hi

I have this 2010 database that has been working fine for a long time on several different machines. The database is split and encrypted with the be on a network and the fe in each user's computer. It has been working fine on XP and 7 32-bit and 64-bit. The number of users is approximately 20.

Three new machines were built last week and all three have a problem. When they start the db it gets back to them with "The database cannot be opened because the VBA project contained in cannot be read. The Database can be opened only if the VBA is first deleted. Deleting the VBA project removed all code from modules, forms and reports. You should back up your database before attempting to open the database and deleted the VBA project.
To create a backup copy click Cancel and then make a backup copy of your database. Top open the database and delete the VBA project without creating a backup copy, click OK."


These three machines have Windows 7 64-bit (just like me) using full 32-bit versions of Access (just like me). These were users that had the db previously and had no issues. The only change is that they got the new computers. We use roaming profiles at our company but this has not been a problem in the past. The IT guys say that nothing is different with these installations when compared to others in the past. The db installation file is the same I have used in the past and was tested on a separate computer yesterday successfully.

IT people has uninstalled the Office applications and reinstalled them to see if that took care of the issue but no luck. The IT department is becoming...a little less cooperative now...

BTW, the database is still in use by the rest of the users with no issues whatsoever.

Tomorrow I'll be able to remote login into one of these computers to experience the issue by myself and try to troubleshoot it.

What should I look at? Suggestions on what could be causing this? Anything stands out?

I really am at a loss on this...

thanks

mafhobb
 
mafhobb, (highly) sounds like Corruption of the code.. Try Compact and Repair..

Try it if it does not help, try Decompiling the DB.. Or import all objects into a New empty DB..
 
If this was the case....why would the same install file work fine on a different machine just as it does not on those three machine?

mafhobb
 
Yes. full versions. Updated to the latest versions.
 
As far as I know, Corruption occurs at any level and it never plays by the rule.. So I am basing my guess as per your initial post
The database is split and encrypted with the be on a network and the fe in each user's computer.
So at the time of distribution there would not have been any problem.. Might be someone tampered with the FE after distribution..

Or is there any piece of Code that is set to Run as soon as the DB file is opened? That might possibly corrupt it.. But again, not entirely sure..

Sorry if this is not the answer you were looking for.. But that error message occurs (mostly) when there is corruption of VB code involved..
 
I've been told (I have not seen it in person yet) that right after that error, the Autoexec macro also returns an error. I do not know if this related to a corruption issue that causes the first error or if it is the first error that causes the second.

mafhobb
 
Can a compact and repair be done on just the front end?
 
Is this through the options menu? Can it be done programatically?
 
Try this.

Get a copy in its original format. I assume that is a 2003 or 2007 copy. Make sure this is original format and has not been converted or made into an mde copy.

Make sure this is working correctly. If so then copy that to one of your new machines and convert it there.

Hope this works for you.

The best fix is to swap all machines over to Access 2003. A much superior product.
 
Last edited:
JHB's link confirms what I said or tried to say.

This is the most likely cause of your problem.
 
JHB. Yes, I had seen that link and I had made sure that the offending computers were updated to the latest patches. Id did not make a change.

Rainlover, your suggestion is very close to what I did to fix the problem.

I logged into the offending machine and after several changes with no success I went ahead and copied my accdb onto that machine and that gave me a different error...a missing reference. It was an accessimage plugin. I copied the accessimage install file onto the offending machine and then the accdb worked fine.

I went back to my computer, created the accde file and used createinstall to create my install file including the accessimage plugin and created the install file, but that did not work on the offiending machine...same VBA error...

Then I created the accde on the offending machine using the accdb I had transfered earlier and that worked fine on the offending computer, so I transfered the new accde to my computer and created the install again using that file. Now it works OK.

It remains to be seen if the new install file will work on the other two offending machines. I'll find out later today.

I guess I had two problems; one the missing reference for the two dll files that should have been installed prior to installing the db (they were installed on the older machines but not on the new ones) and then some kind of corruption on my own Access copy when it creates the accde from the accdb.

I'll be reinstalling my Access soon...

mafhobb
 
I guess I had two problems; one the missing reference for the two dll files that should have been installed prior to installing the db (they were installed on the older machines but not on the new ones) and then some kind of corruption on my own Access copy when it creates the accde from the accdb.

There is no corruption as far as I can see. What I suggested is not a quick fix or a work around. It is the proper way to do things.
 

Users who are viewing this thread

Back
Top Bottom