Like in a Dlookup

steve1111

Registered User.
Local time
Today, 01:46
Joined
Jul 9, 2013
Messages
170
Hi,

I am trying to use a Like statement in a VBA dlookup, as some of the fields in a third party db i cannot manage are variations of fields in a table i need.

i currently have:

Me.Clinic.Value = DLookup("[ID]", "dbo_Clinics", "[Name] = Like '%' & [Forms]![frmHome]![subaTcTools].[Form]![subbDST].[Form]![txtClinic] & '%'")

but i get a runtime error 3075 missing operator.

Thanks for any help!
 
Couple of issues. Try

Me.Clinic.Value = DLookup("[ID]", "dbo_Clinics", "[Name] Like '*" & [Forms]![frmHome]![subaTcTools].[Form]![subbDST].[Form]![txtClinic] & "*'")
 
Thank you Paul
 

Users who are viewing this thread

Back
Top Bottom