DLookUp Syntax for multiple numeric critera

kelsita_05

Registered User.
Local time
Today, 05:33
Joined
Aug 23, 2005
Messages
52
I've been staring at this for way too long now. Could someone review my DLookUp to figure out what's wrong with my syntax?

=DLookUp("[transrate]","tblLinguist_Lang","[LangID]= " & [Forms]![frmmainentrytest]![txtLangID] & AND "[LinguistID]= " & [Forms]![frmmainentrytest]![txttransID] &)

All the fields in the criteria are numeric. I'm using it as the control source of a textbox, hence the beginning =.

Thank you!
 
I stared at that thread for a while too. I think the answer may be to pick this up again tomorrow after some sleep. Thanks, though!
 
Try this;
Code:
=DLookUp("[transrate]","tblLinguist_Lang","[LangID]= " & [Forms]![frmmainentrytest]![txtLangID] & [COLOR="Red"]"[/COLOR] AND [LinguistID]= " & [Forms]![frmmainentrytest]![txttransID])

You need to include the And operator as part of your string (note highlighted double quote mark), and you had a trailing ampersand that was not required.
 

Users who are viewing this thread

Back
Top Bottom