115 pts.
 Master/Child Link problem in Subform
Hi, I needed to add a new table to my database, so I added it and created a one-to-many relationship with the parent table. I then created a form and used the subform wizard to make it into a subform. The Master and Child links are the primary key in the parent table and the foreign key in the child table. I have three other forms, and did this exact same process with no issues whatsoever. This time, the foreign key is not populating in the child table. Not only that, but whatever information I put into a field child table bleeds across to all the records, even if they're entirely different people. For example, I went to Person A in the parent form, opened up the child form and entered a date. Then I went to a different person in the parent form and opened up the child form and the date field(which should have been blank for Person B) had the same date I entered for person A. I don't know what could be wrong. I followed the exact process as I have before with no variation, and the other times it worked beautifully. This time it's not working at all. I've spent hours trying to troubleshoot this and it's making me crazy. Could someone please advise me? Thanks!

Software/Hardware used:
ASKED: October 8, 2009  11:46 PM
UPDATED: October 9, 2009  3:21 PM

Answer Wiki:
I just figured out the answer. I coded the command button to open the subform/child, instead of just making it visible. This bypassed the main form/parent and caused the problem. When I set the subform as invisible and made it visible when the command button was clicked, the foreign key was there. That way the subform would tied to the proper person in the main form.
Last Wiki Answer Submitted:  October 9, 2009  3:21 pm  by  Dataempress   115 pts.
All Answer Wiki Contributors:  Dataempress   115 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _