Hi Richard, My customer table is linked to a contact table that shows the 'managers' of different locations. I am trying to add a button to my customercontactF which will open up my communications form with two where criteria (customerID and contactid) So i can not only see customer communications, but communications with the relevant customers employee. I've tried figuring this out by googling...this is what I've come up with... DoCmd.OpenForm "CommunicationF", , , "CustomerID='" & Me.CustomerCombo & "' AND ContactID='" & Me.ContactCombo & "'"
This isn't working - could you please tell me where I'm going wrong.
Thanks Lynda
Reply from Richard Rost:
So your CommunicationF has both a CustomerID and a ContactID on it, and you want to show records for BOTH? In that case, you need an OR condition, not an AND condition.
Docmd.Openform "CommF",,,"CustomerID=" & X & " OR ContactID=" & Y
Sorry, only students may add comments.
Click here for more
information on how you can set up an account.
If you are a Visitor, go ahead and post your reply as a
new comment, and we'll move it here for you
once it's approved. Be sure to use the same name and email address.
This thread is now CLOSED. If you wish to comment, start a NEW discussion in
Access Expert 11.