Solved

MS Access 2007 vs 2003 SubForm Event Sequence

Posted on 2008-10-24
9
1,355 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
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!

 
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

Back Up Your Microsoft Windows Server®

Back up all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Question has a verified solution.

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

A simple tool to export all objects of two Access files as text and compare it with Meld, a free diff tool.
Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
Familiarize people with the process of utilizing SQL Server views from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Access…
In Microsoft Access, learn the trick to repeating sub-report headings at the top of each page. The problem with sub-reports and headings: Add a dummy group to the sub report using the expression =1: Set the “Repeat Section” property of the dummy…

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