Solved

Strange behavior in Access 2007

Posted on 2011-09-02
6
306 Views
Last Modified: 2012-05-12
I have an access application that is used in both Access 2000 and Access 2007, as most of the ones here at work are...

We are getting some strange behavior in one particular app that is just being built.  We Have some code that fires in the load event of a form...but it is not firing in Access 2007 until the form is closed...maybe even when it is unloaded.    I have tried it on two Office 2007 machines and it happens on both.

Head scratch...
0
Comment
Question by:snyperj
6 Comments
 
LVL 61

Assisted Solution

by:mbizup
mbizup earned 100 total points
ID: 36473539
Can you post a sample illustrating this issue?
0
 

Author Comment

by:snyperj
ID: 36473667
I have just confirmed that the form load event is firing just before the form unload event, but only in Office 2007.  
It works fine in Office 2000.  ?  

I just found this link:
http://bytes.com/topic/access/answers/199175-load-event-active-form-fires-when-access-closes

Nice to know I am not going crazy.  This is the same exact problem.  
0
 

Author Comment

by:snyperj
ID: 36473702
Unfortunately (for me) the steps to reproduce, don't reproduce it.  Attached is the db I made following the instructions in the article... but it doesn't happen in this db in either Office 2000 or 2007...   grrr.

...but it is happening with mine. At least I can look into the hidden form issue as the cause and see if I can work around it.  It's odd, because I have used hidden forms, etc in other apps without this occurring... so there must be some other missing link to the problem.
test-db1.mdb
0
Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

 
LVL 74

Accepted Solution

by:
Jeffrey Coachman earned 400 total points
ID: 36473868
Seems to work fine for me?

Are you compiling your code on a regular basis?
Are you running the compact/repair utility on a regular basis?

Do all machines all have the same libraries loaded in the VBE?

Note that your DB is in the 2003 format, ...so not all things may be available when the DB is opened by the Access 2000 users.

Try saving/converting a copy of this DB in the 2000 format...
Then compile the code, then run the C&R utility, ...
...then test for this issue.

Remember that Access development recommends that you develop the DB in the lowest format that the users will be using.

So if the lowest version your users will be using is 2000 then *Convert* the DB to the 200 version.
And *Only* make design changes to the DB in Access 2000.

JeffCoachman
0
 

Author Closing Comment

by:snyperj
ID: 36474048
Thanks for the tips.  I tracked my problem down to something entirely different as the culprit.  I have a subform on this form in detail section and I was hiding / unhiding the detail section in sections of the form code instead of hiding / unhiding the subform control itself.  Once I made the change, it works fine.  Not sure what is related to what in this case... but moving on...
0
 
LVL 42

Expert Comment

by:dqmq
ID: 36474272
I cannot reproduce the problem either and concur with Jeff.   Suspect it's an issue with mixed versions.  Using 2003 format from a 2000 executable is without a doubt questionable.  
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

Introduction When developing Access applications, often we need to know whether an object exists.  This article presents a quick and reliable routine to determine if an object exists without that object being opened. If you wanted to inspect/ite…
Regardless of which version on MS Access you are using, one of the harder data-entry forms to create is one where most data from previous entries needs to be appended to new records, especially when there are numerous fields and records involved.  W…
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now