Update data in a form based on record selection in another subform

W

WillW

I need for data in Form2 to change based on the selection of records in
Subform1 of Form1.

Subform1 displays continuous records, and when tabbing to or selecting those
records I'd like for Form2 to automatically display related data. Both
Subform1 and Form2 have a common primary key.

Hope this is clear. I'm sure I've made this work in the past, and I hoped
existing posts and Access Help would get me back on track -- but so far, no
luck.

Thanks.
 
M

Marshall Barton

WillW said:
I need for data in Form2 to change based on the selection of records in
Subform1 of Form1.

Subform1 displays continuous records, and when tabbing to or selecting those
records I'd like for Form2 to automatically display related data. Both
Subform1 and Form2 have a common primary key.


Try using something like this in sunform1'a Current event:

Forms!Form2.Filter = "pkfield=" & Me.pkfield
Forms!Form2.FilterOn = True
 

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