Solved

MS Access 2007 vs 2003 SubForm Event Sequence

Posted on 2008-10-24
9
1,354 Views
Last Modified: 2013-11-28
Hello,
I am opening the same .mdb file on two separate machines. One machine is 2003 version and the other 2007. When I choose a button on a switchboard to open a form in version 2003, it references the subform's event sequence first(even though rs![Argument] in switchboard routine points to main form The db was built on 2003), and this how I want it to run. However, on 2007 the parent form's Form_Load() Event is fired first which causes problems. Why does the sequence of events called differ from the same exact .mdb between versions 2003/2007?

Thank you
0
Comment
Question by:jcampanali
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 4
9 Comments
 
LVL 74

Assisted Solution

by:Jeffrey Coachman
Jeffrey Coachman earned 250 total points
ID: 22800978
jcampanali,

First, I could not duplicate your issue.
I put message boxes on both forms Opening Event Sequences(Open,Load,Resize,Activate,Current)
In both Access 2003 and Access 2007 the subform events fired first.

What happens when you open this form *without* the switchboard in 2003 and 2007.

JeffCoachman
0
 
LVL 4

Author Comment

by:jcampanali
ID: 22801207
Good question, I'm not sure and since I've left work I will have to try on Monday. I thought it to be a 2007 issue. I even went so far as to change the form in the switchboard call to the subform and strangely it called only the Load event skippin over OnCurrent and returning to switchboard code. With 2003 both events are called. And really it's the OnCurrent Event I need to establish data in the subform. Could I call an event from another one as a possible solution?
0
 
LVL 74

Assisted Solution

by:Jeffrey Coachman
Jeffrey Coachman earned 250 total points
ID: 22801915
Yes, but I am not sure it would work.
Because there is the Order of events (That I listed above) that *Must* be followed and cannot be changed.
0
Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

 
LVL 4

Author Comment

by:jcampanali
ID: 22813175
OK, What I noticed when stepping through on the combo box's After_Update event for form  in question(completely by-passing Switchboard) is that the subforms load correctly on 2007 version, however switching from code view to form view shows a superimposed switchboard form(no stops were placed on switchboard). If I run through it in real time, no switchboard form appears, but the sub forms do not populate. I have to re-select from the combo box to populate subform data. After that it's fine as long as the form remains open.
0
 
LVL 74

Assisted Solution

by:Jeffrey Coachman
Jeffrey Coachman earned 250 total points
ID: 22819424
So, ... problem solved?
0
 
LVL 4

Author Comment

by:jcampanali
ID: 22821729
Umm, no because in real time the subform does not populate due the fact that the 2007 version opens main form's events first instead of subform -which is what happens in 2003.
0
 
LVL 74

Assisted Solution

by:Jeffrey Coachman
Jeffrey Coachman earned 250 total points
ID: 22824745
What happens if you make a simple Mainform/Subform in Access 2007, and put messages on all of the Opening events?
(Open, Load, Resize, Activate, Current)
0
 
LVL 74

Assisted Solution

by:Jeffrey Coachman
Jeffrey Coachman earned 250 total points
ID: 22824810
.. a "Real" Mainform/Subform (Customers=Main, Orders=Sub)
0
 
LVL 4

Accepted Solution

by:
jcampanali earned 0 total points
ID: 22869814
I'll revisit later. Too many pressing issues. Thanks
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It’s the first day of March, the weather is starting to warm up and the excitement of the upcoming St. Patrick’s Day holiday can be felt throughout the world.
Access custom database properties are useful for storing miscellaneous bits of information in a format that persists through database closing and reopening.  This article shows how to create and use them.
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

726 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