Linked form questions

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a linked field in a form so that when a customer is picked from a list
in my Order Entry form, it looks up, and displays, the salesman from the
Customers form/table. The field showing the salesman is NOT enabled and IS
locked (display only). The code that this field uses to look up is:
=DLookUp("[Employee]","Customers","[CompanyName]='" & [Customer] & "'")

I have a weird problem. This works GREAT on all customers, and all salesmen,
with one exception. ONE customer comes up with the salesman as #Error. And I
can't explain it, because the same salesman comes up fine on other customers,
and as far as I can tell, all other customers come up fine.
Any idea what's going on? If it helps, the customer list on the Order Entry
form is a combo box, as is the Salesman list on the Customers form, and I've
checked both of them--they ARE selected from the list and everything seems to
be correct.

Any suggestions/comments/thoughts?
Thanks!
Melissa
 
I will try the change, though I don't know what it will do. This customer has
a salesman assigned to it, let's call him Sam Smith. This name is selected
out of a pull-down menu on the "Customers" form, and I have checked that this
customer's salesman was SELECTED from the list and not typed in. This
salesman has OTHER customers, and his name comes up perfect on all of his
other customers, just not on this one, lets call it CustomerA.
I simply cannot explain why all other customers pull up their respective
salesman and this one doesn't. I will try that change tomorrow at work.
Thank you.
 
Back
Top