Tough Problem With Two Subforms

llyal

Registered User.
Local time
Today, 23:56
Joined
Feb 1, 2000
Messages
72
Tough Problem With Two Subforms

I have a form with a combo box and a subform; the combo box updates the recordsource of the subform with the AfterUpdate() event; no problems; I am trying to convert this into a form with two subforms, one subform replacing the functionality of the combo box- by moving through the records of this subform, the other subform's recordsource gets updated;

with all my attempts, using OnCurrent, OnFocus, other events, i either get no updates, or Access goes into an infinite loop; i have had success using a subform to control a subform if the target subform is only filtered by one field; but in this scenario i am using complex SQL and need to update the RecordSource directly;

Has anybody figured out how to do this? What do ido?

Thank you!

--llyal
 
Thanks for the input; another way to do what you have done, as explained in the Access Developers Handbook by Litwin, Getz, and Gilbert, is to use the OnCurrent event of the first subform to update the textbox, that will then be used update the second subform using the LinkMaster/ LinkChiild properties;

In my situation, i am trying to update the second form, not by a field or two (like can be done as explained above), but by a complex dynamic SQL statement; to do this, i need to change the RecordSet of the second subform and requery; I cannot do this using the above method; because of the way forms are designed, i don't think i can do this in Access; I ended up using a Listbox control (not my ideal solution); when i use a subform, i kept creating infinite loops;

Thanks for the help!

--llyal
 

Users who are viewing this thread

Back
Top Bottom