Child/Master fields

  • Thread starter Thread starter DA
  • Start date Start date
D

DA

My database for tracking Confidentiality agreements
consists of a table for Company Information and a table
for Agreement details with the relationship based on
CompanyName. I have a form that has the Company
information and a subform with some of the agreement
details (NDA_ID,ExpDate,Requestor,etc). What I would like
to do is be able to insert another subform to display the
rest of the agreement details for the record currently
selected in the first subform. The first subform is in
continuous- datasheet view. The second subform has Link
Master Fields set to:[frmSubform1].Form![NDA_ID] and Link
Child Fields to NDA_ID but it only displays details about
the first record in Subform1. What am I doing wrong? Help
please!
 
DA, You need to reference your subform1 through your main form

Link Master Field:
Forms![frmYourMainForm]![frmSubform1].Form![NDA_ID]

Then set the On Current event of subform1 to something like


Private Sub Form_Current()
Forms!frmYourMainForm!frmSubform2.Requery
End Sub

Hope it helps!
 
Thanks for pointing me in the right direction.
-----Original Message-----
DA, You need to reference your subform1 through your main form

Link Master Field:
Forms![frmYourMainForm]![frmSubform1].Form![NDA_ID]

Then set the On Current event of subform1 to something like


Private Sub Form_Current()
Forms!frmYourMainForm!frmSubform2.Requery
End Sub

Hope it helps!

--
Reggie

----------
My database for tracking Confidentiality agreements
consists of a table for Company Information and a table
for Agreement details with the relationship based on
CompanyName. I have a form that has the Company
information and a subform with some of the agreement
details (NDA_ID,ExpDate,Requestor,etc). What I would like
to do is be able to insert another subform to display the
rest of the agreement details for the record currently
selected in the first subform. The first subform is in
continuous- datasheet view. The second subform has Link
Master Fields set to:[frmSubform1].Form![NDA_ID] and Link
Child Fields to NDA_ID but it only displays details about
the first record in Subform1. What am I doing wrong? Help
please!


.
 
Back
Top