Hi all,
I am looking for a little syntax advice when using multiple criteria in a dlookup function. I have the following VBA:
Me![Text228] = DLookup(“[CLIN_DESCRIP]”, “Cams_Piin_Data2”, “[PIIN_CODE] = ‘” & Forms![supmod -> Mod]![PIIN_CODE] & “‘” And “[CLIN] = ‘” & Me![CLIN] & “‘”)
It will compile with no error but when run I get a run time error 13( type mismatch). Both PIIN_CODE and CLIN are text fields in the table.
If i drop one of the criteria it works fine so I thought I could just add an AND with a second criteria but it appears that there is more to it than that.
Can someone point me in the right direction?
Thanks you
Kevin