Subform Not Responding

  • Thread starter Thread starter Sal R. via AccessMonster.com
  • Start date Start date
S

Sal R. via AccessMonster.com

I’m trying to get a subform to respond to the click of a dropdown on my main
form. The main from dropdown has the following code:

Private Sub ComboCoName_AfterUpdate()
Me!TxtCoID = Me!ComboCoName.Column(1)
Me!CompanyName = Me!ComboCoName.Column(0)

End Sub

The subform has the following code:

SELECT tblCkList.VendorRqmnt, tblCkList.Companyid
FROM tblCkList
WHERE (((tblCkList.Companyid)=[Forms]![frmDataEntry]![txtCoID]));

But when I click to choose a company name from the dropdown, the subform
doesn’t display any records. Also, I made the master and child links on
subform point to companyid.

Can anyone help me with this?

Thanks,
Sal
 
Make this simple.
Just use the TxtCoID as the MasterLink and the subforms matching field
(Company ID) for ChildLink. Then get rid of the WHERE clause in the query
for the subform.
HTH
Bill
 
Back
Top