MS Access 2003 - The Expression on click / on unload error

Hi,

I am getting above error while clicking on any button or closing any form.

I tried Compact and Repair. Importing all items in a new database.

It's  working fine in 2007.

PFA the screen shot.

Regards,
Sandesh
MS-Access-Error.jpg
Sandesh555Asked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Kelvin SparksCommented:
THis usually means you have a code error/corruption or a reference is missing.

Toheck references, in any code module, goto menu tools>references. Look for any that are marked as missing. You must file the file (dll, ocx etc...) and select it and ernsure it shows as selected.

Then try an compile the database - Menu Debug>Compile


Kelvin
0
Sandesh555Author Commented:
Hi Kelvin,

All references are ok, how to find if there is any corruption.

Regards,
Sandesh
0
Kelvin SparksCommented:
Can you complie the database?

Kelvin
0
Big Business Goals? Which KPIs Will Help You

The most successful MSPs rely on metrics – known as key performance indicators (KPIs) – for making informed decisions that help their businesses thrive, rather than just survive. This eBook provides an overview of the most important KPIs used by top MSPs.

Kelvin SparksCommented:
Can you compile the database (typo above)
0
mbizupCommented:
Has this database ever worked on Access 2003 systems, or is this a new problem?

Can you post a little more detail about what leads to this error - which forms/buttons/etc...

And if possible post a sample copy of your database.
0
Sandesh555Author Commented:
Hi,

Yes I can compile the database. Earlier it was working but suddenly started giving this error. It's giving this error on each event.
PFA the database.
Regards,
Sandesh
Expedite-V1.2.zip
0
peter57rCommented:
You'll have to post a version that does not have a vba password.
0
Sandesh555Author Commented:
0
mbizupCommented:
I agree that there is some form of corruption in that database.

If you remove and then re-paste  (take them out and then put them back in  again) the on click, on load, or other events that are causing this error, you'll find that they will start wotking normally again.

I haven't tried this, but before going through all the effort of removing and restoring your code, you might try decompiling it.  See the instructions here - and make a backup first:

http://www.experts-exchange.com/Microsoft/Development/MS_Access/Q_27661663.html
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
mbizupCommented:
Also,  I don't know if this caused the problem or not, but since you are developing a database for users with different versions of Access, make sure that all of your development is done in the lowest version.

In other words, if you are mixing Access 2003 and Access 2007, all of your development should be done in Access 2003.
0
peter57rCommented:
There is some form of corruption which can be fixed using a decompile.
Use a copy of your database and execute the following command (adjusted for your own folder locations) from the Run dialog.

"C:\Program Files\Microsoft Office\OFFICE11\MSACCESS.EXE" "databasefolder\Rio Tinto - Expedite V1.2.mdb" /decompile
0
mbizupCommented:
Sorry - I gave you the wrong link.  These are the decompile instructions I'd meant to post:

http://www.granite.ab.ca/access/decompile.htm
0
Dale FyeOwner, Developing Solutions LLCCommented:
Giving credit where credit is due, you might want to try MX's solution and close Access, then reboot your computer.

Dale
0
mbizupCommented:
Dale,

Did you download the DB and try that?  It doesn't work for me.

MX's rebooting idea clears phantom breakpoints, which looks to me like a different problem (this one is resolvable by cut/pasting the code, and I imagine by decompiling too).
0
Dale FyeOwner, Developing Solutions LLCCommented:
Miriam,

No, cannot download while I'm at work.  I would concur that a decompile is in order.

But whenever I run into one of those situations that just doesn't make sense, where something I know should work isn't, I blame it on Windows and try rebooting.
0
Sandesh555Author Commented:
Hi Team,

This MS access 2003 db is using MS Access 12.0 object library reference.

Is it causing problem? and how to change the reference from 12 to 11.
It says object in use while removing the reference and did not add 11 while 12 is already there.

Please suggest.

Regards,
Sandesh
0
Kelvin SparksCommented:
You have to make sure that no code is running. Start the database, holding down the shift key to ensure no autoexec macro runs. Then goto a VBA page (any one) and deselect the 12 version, then scroll down and find the 11 version. May pay to check it is installed first.


Kelvin
0
Sandesh555Author Commented:
Hi Kelvin,

I could not able to remove reference, as it says cant remove control or reference: in use.

Regards,
Sandesh
0
mbizupCommented:
Did you try cutting / pasting a block of code as suggested earlier?

This minor edit fixed the corruption for me in your sample.
0
mbizupCommented:
(I did the edit on an Access 2003 machine,  btw )
0
Sandesh555Author Commented:
Thanks
0
Sandesh555Author Commented:
NA
0
mbizupCommented:
Sandesh - are you having trouble with  EE's user interface?

Click the Request Attention button if you need a Moderator's help.
0
Sandesh555Author Commented:
Thanks
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Access

From novice to tech pro — start learning today.