DCount not working?

Greetings,

i'm filtering a recordset, then counting how many records meet the criteria. I know the filter is working right but DCount is not working right. I'm sure that I'm overlooking something so could someone help me out. Thanks!
.Filter = "[RecID] = Null"
i = DCount("*", "qry_ProcFormS02_Combobox_Values", "[RecID] = Null")

Open in new window

LVL 10
Anthony BerenguelAsked:
Who is Participating?
 
Jeffrey CoachmanConnect With a Mentor MIS LiasonCommented:
Try these perhaps:

= DCount("*", "qry_ProcFormS02_Combobox_Values", "[RecID] Is Null")

= DCount("*", "qry_ProcFormS02_Combobox_Values", "IsNull([RecID]")
0
 
Jeffrey CoachmanMIS LiasonCommented:
sorry:
or:
= DCount("*", "qry_ProcFormS02_Combobox_Values", "IsNull([RecID])")
0
 
Anthony BerenguelAuthor Commented:
Thanks, boaq2000. I also just  figured out that i = DCount("*", "qry_ProcFormS02_Combobox_Values", "[RecID] is null") works as well.

0
 
Jeffrey CoachmanMIS LiasonCommented:
OK

But try to us the caps, this is how that Autocorrect will convert it to in many cases
0
 
Anthony BerenguelAuthor Commented:
will do. Thanks! And special thanks for the quick help!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.