Dlookup Type Mismatch Error (1 Viewer)

ria4life

Registered User.
Local time
Yesterday, 16:14
Joined
Feb 24, 2016
Messages
40
I keep getting type mismatch error with this code.
The first part of the dlookup works ok...the second part after "and" seem to generate the error.



Code:
Me.I1 = DLookup("Occurance", "[Qry_Availability1]", "Date_Selected = Sig1" And "[title] = '" & Text89 & "'")

Title is in short text format in the table
text 89 is unformatted....but contains text

Any help is greatly appreciated.
 

pbaldy

Wino Moderator
Staff member
Local time
Yesterday, 16:14
Joined
Aug 30, 2003
Messages
36,124
The quotes on both sides of And need to be deleted.
 

ria4life

Registered User.
Local time
Yesterday, 16:14
Joined
Feb 24, 2016
Messages
40
WOW Cant believe it was a simple as that.
thank you much
 

pbaldy

Wino Moderator
Staff member
Local time
Yesterday, 16:14
Joined
Aug 30, 2003
Messages
36,124
No problem, though I don't quite understand the date criteria.
 

mresann

Registered User.
Local time
Yesterday, 16:14
Joined
Jan 11, 2005
Messages
357
You may wish to put "Solved" in the title as well.
 

Users who are viewing this thread

Top Bottom