Linking Table in Forms

N

Nanette

I've created several tables because of a many to many relationship:

Cabinets
CabinetDetails
LinkCabAndParts
Parts
PartDetails

I've been trying to create a form that will have several of the fields from
all of the tables using sub-forms. I created an initial Cabinet form with a
subform CabinetDetails, added a LinkCabAndParts subform just to see if things
are working correctly, and then added another subform called Parts with its
own subform PartDetails. It seems to be working even though the Link Child
Field on the Parts subform is connected to the Cabinet form instead of the
LinkCabAndParts subform.

How do I get the field id_Part in the Parts subform to be copied over and
entered into the id_Part field in the LinkCabAndParts subform?
 
N

Nanette

Hi Alex,

Yes, I believe that I need to have a link between 2 subforms. Being sort of
new at this, I don't completely understand your answer. Do you mean to add a
textbox on the main form and put the expression =[Parts].Form!id_Part in the
Control Source? And then link the LinkCabAndParts to the textbox by using the
Child Link and Master Link options?

Alex Dybenko said:
Hi,
do you mean you need a link between 2 subforms? then you can add a textbox
on a main form with expression =[Parts].Form!id_Part and then link
LinkCabAndParts to that textbox

--
Best regards,
___________
Alex Dybenko (MVP)
http://alexdyb.blogspot.com
http://www.PointLtd.com

Nanette said:
I've created several tables because of a many to many relationship:

Cabinets
CabinetDetails
LinkCabAndParts
Parts
PartDetails

I've been trying to create a form that will have several of the fields
from
all of the tables using sub-forms. I created an initial Cabinet form with
a
subform CabinetDetails, added a LinkCabAndParts subform just to see if
things
are working correctly, and then added another subform called Parts with
its
own subform PartDetails. It seems to be working even though the Link Child
Field on the Parts subform is connected to the Cabinet form instead of the
LinkCabAndParts subform.

How do I get the field id_Part in the Parts subform to be copied over and
entered into the id_Part field in the LinkCabAndParts subform?
 
A

Alex Dybenko

Hi,
yes, this is what I mean. for LinkCabAndParts subform in Master Link option
you put name of this textbox and LinkCabAndParts - field with part id of
this subform

--
Best regards,
___________
Alex Dybenko (MVP)
http://alexdyb.blogspot.com
http://www.PointLtd.com

Nanette said:
Hi Alex,

Yes, I believe that I need to have a link between 2 subforms. Being sort
of
new at this, I don't completely understand your answer. Do you mean to add
a
textbox on the main form and put the expression =[Parts].Form!id_Part in
the
Control Source? And then link the LinkCabAndParts to the textbox by using
the
Child Link and Master Link options?

Alex Dybenko said:
Hi,
do you mean you need a link between 2 subforms? then you can add a
textbox
on a main form with expression =[Parts].Form!id_Part and then link
LinkCabAndParts to that textbox

--
Best regards,
___________
Alex Dybenko (MVP)
http://alexdyb.blogspot.com
http://www.PointLtd.com

Nanette said:
I've created several tables because of a many to many relationship:

Cabinets
CabinetDetails
LinkCabAndParts
Parts
PartDetails

I've been trying to create a form that will have several of the fields
from
all of the tables using sub-forms. I created an initial Cabinet form
with
a
subform CabinetDetails, added a LinkCabAndParts subform just to see if
things
are working correctly, and then added another subform called Parts with
its
own subform PartDetails. It seems to be working even though the Link
Child
Field on the Parts subform is connected to the Cabinet form instead of
the
LinkCabAndParts subform.

How do I get the field id_Part in the Parts subform to be copied over
and
entered into the id_Part field in the LinkCabAndParts subform?
 
N

Nanette

Hi Alex,

I haven't gotten a chance to do this yet, buy I'll get to it soon. Thanks
for the instructions!

Alex Dybenko said:
Hi,
yes, this is what I mean. for LinkCabAndParts subform in Master Link option
you put name of this textbox and LinkCabAndParts - field with part id of
this subform

--
Best regards,
___________
Alex Dybenko (MVP)
http://alexdyb.blogspot.com
http://www.PointLtd.com

Nanette said:
Hi Alex,

Yes, I believe that I need to have a link between 2 subforms. Being sort
of
new at this, I don't completely understand your answer. Do you mean to add
a
textbox on the main form and put the expression =[Parts].Form!id_Part in
the
Control Source? And then link the LinkCabAndParts to the textbox by using
the
Child Link and Master Link options?

Alex Dybenko said:
Hi,
do you mean you need a link between 2 subforms? then you can add a
textbox
on a main form with expression =[Parts].Form!id_Part and then link
LinkCabAndParts to that textbox

--
Best regards,
___________
Alex Dybenko (MVP)
http://alexdyb.blogspot.com
http://www.PointLtd.com

I've created several tables because of a many to many relationship:

Cabinets
CabinetDetails
LinkCabAndParts
Parts
PartDetails

I've been trying to create a form that will have several of the fields
from
all of the tables using sub-forms. I created an initial Cabinet form
with
a
subform CabinetDetails, added a LinkCabAndParts subform just to see if
things
are working correctly, and then added another subform called Parts with
its
own subform PartDetails. It seems to be working even though the Link
Child
Field on the Parts subform is connected to the Cabinet form instead of
the
LinkCabAndParts subform.

How do I get the field id_Part in the Parts subform to be copied over
and
entered into the id_Part field in the LinkCabAndParts subform?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top