Filter by form (No records Msgbox?)

GeoffO

New member
Local time
Today, 04:52
Joined
Aug 13, 2001
Messages
6
HiI have a search form that opens with "filter by form", the problem is if no records
are returned the form goes blank, how do I get it to display a msgbox?. I've seen
some posts saying use "DCount"

If DCount ("*","QueryName")<= 0 then
MsgBox "No Records Match"
Exit Sub
End If


But since my form starts with Filter by Form, I have no name for the filter?.("QueryName")

Thanks

Geoff
 
Hi

Use Form.RecordsetClone.RecordCount as the query name?

Thanks

Geoff
 

Users who are viewing this thread

Back
Top Bottom