How do I count the number of checked boxes on a report?

Hi there.  I need to count the number of cases with a checked box for a particular field on a report attached to the table, but am not sure how to do this - have had a look elsewhere on EE but can only seem to find how to do this on a form in a live sense, which I don't need to do - I just need a count to appear on the report.  Any idea how I do that?  
fernandowebAsked:
Who is Participating?
 
Jim HornConnect With a Mentor Microsoft SQL Server Developer, Architect, and AuthorCommented:
In Access, True is -1 and False is 0, so if you add up the values of all the check boxes you will get a minus # of checked boxes.

If you need this in a footer on the report, =Abs(Count(YourCheckBoxField))
0
 
fernandowebAuthor Commented:
Thanks for that, although for some reason all that seems to give me is the total number of checkboxes (ie - 60, and there are 60 clients on the system) as opposed to the number which are checked (which is just 4)

Sorry too this question seems to have partially ended up in the C# programming category which wasn't intended...!
0
 
omgangIT ManagerCommented:
I think jimhorn meant to say
=Abs(Sum(YourCheckBoxField))

OM Gang

PS - I don't want the points - typo on jim's part
0
 
fernandowebAuthor Commented:
Thanks for that - works great now
0
 
fernandowebAuthor Commented:
Thanks very much
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.