Link to home
Start Free TrialLog in
Avatar of galneweinhaw
galneweinhaw

asked on

DLookup in the Control Source Property of a Form Text Box

This is what I have in the Control Source

=DLookUp([Optic Description],[Optics],[Optics]!OpticID=[Top Optics])

but it gives me: #Name?


I am trying to look up a description from the Optics table where The OptiicID is the same as the current displayed record on the form.

Thanks!
Avatar of jmantha709
jmantha709

Try :

=DLookUp("[Optic Description]";"[Optics]";"[Optics] = " & Form![Top Optics])
Try this:

=DLookUp("[Optic Description]","[Optics]","[OpticID] = " & Me.[Top Optics])
Sorry, mistake, here's to good one :

=DLookUp("[Optic Description]";"[Optics]";"[OpticID] = " & Form![Top Optics])
ASKER CERTIFIED SOLUTION
Avatar of jmantha709
jmantha709

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
we have fast typers here :)
BTW: the semi-colon is valid in a french setup, for example (see the Windows "list separator"), and the "Me." syntax does not work in a control source...
Cheers!