Subform Not Responding

  • Thread starter Sal R. via AccessMonster.com
  • 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
 
B

Bill

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
 

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

Similar Threads


Top