DLookup Syntax Problem

G

Guest

I'm trying to use a DLookup to lookup a value on the current form and return
a text string from a table. However, I think I have problems with my
Criteria syntax.

=DLookup("[Unit]", "Items List", "[Descr] = ' " '
Forms!SUBFORMAirport!ItemSelected " ' ")

[Unit] is the field from where I'm trying to draw the text

Items List is the Database with the info

SUBFORMAirport is the form that I'm currently designing

ItemSelected is the name of the Combo Box control on the current form.

[Descr] is the field to which I'm comparing the value of ItemSelected

What am I doing wrong?
 
A

Al Camp

Jim,
When in doubt, use "full" addressing...
=DLookup("[Unit]", "Items List", "[Descr] =
Forms!YourMainFormName!SUBFORMAirport.Form!ItemSelected")
 

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

dlookup with if 1
DLookup help 6
dlookup 2
Dlookup 4
Trouble with DLookup 3
Access Field won't show as currency in the form, shows just a number (but works fine in the query) 1
Persistant flicker in DLookup 10
DLOOKUP 2

Top