Main form/subform and list box question

  • Thread starter Thread starter D Collins
  • Start date Start date
D

D Collins

Hello,

I have a main form with a subform. On the subform, I
have a list box that I want to use to display records
that match only the ID for the record I'm on. I only
want to see a list of contacts, for example, for that
ID. In the underlying source for the list box, I use
something like this in the criteria:
Forms!frmTheMainFormName!txtSomeID. It seems to only
find the first record's contacts and display them in the
list box for all the records.

Does the list box need to refresh based on the record
it's on?

Thanks, D.
 
Yes, it does.

The LinkMasterFields / LinkChildFields simply filters the Subform's
RecordSource, not the RowSource of the applicable Controls on the Subform.

You need to use the (Main) Form_Current Event to requery the ListBox in the
Subform.
 
Back
Top