Multiple subforms and parent child relations

  • Thread starter Thread starter judith
  • Start date Start date
J

judith

I have a form with 5 subforms on which I'll call A - E
A is master to child B
B is master to child C
the 4 records in B have values 1-4
then
if value of B is 1 or 2 form E is child to B and C
if value of B is 3 or 4 (form D is visible and is child to C AND form E
is child to B and D)
most of this works great but what I am having problem resolving is when
I should requery and set the parameters
At the moment it's all OnCurrent but when I first move from B being 1
or 2 to 3 or 4 or vice versa I get an Enter Parameter box (form E's
recordSource is set in B)
Any advice greatly received - i've been going round in circles on this
 
I have a form with 5 subforms on which I'll call A - E
A is master to child B
B is master to child C
the 4 records in B have values 1-4
then
if value of B is 1 or 2 form E is child to B and C
if value of B is 3 or 4 (form D is visible and is child to C AND form E
is child to B and D)
most of this works great but what I am having problem resolving is when
I should requery and set the parameters
At the moment it's all OnCurrent but when I first move from B being 1
or 2 to 3 or 4 or vice versa I get an Enter Parameter box (form E's
recordSource is set in B)
Any advice greatly received - i've been going round in circles on this

Strange. I'm not sure I understand what this is trying to accomplish,
and it sounds like your Table B is perhaps not properly normalized, if
the relationships to other tables depend on the value in a field!

Could you post the Recordsources of the relavant forms, and your code?
The Enter Parameter suggests that something in E's Recordsource is
referencing a nonexistant field, or perhaps a Master or Child Link
Field or an Order By...

John W. Vinson[MVP]
 
Back
Top