DCount formula

C

Chris

I need to count some yes checkmarks in a grouped report.

I can write
=DCount([NameofField],"qryQueryName","[NameofField]=-1")
This counts all the "yes" marks.

I need it to count the yes marks for a particular group.
Something along the line of
=DCount([NameofField],"qryQueryName","[NameofField]=-1 and
[Reports]![rptName]![Whateverfieldthereportisgroupedby]=
[Query]![qryQueryName]![whateverfieldthereportisgroupedby]

I don't know, but something where the criteria for the
dcount includes what the field the report is grouped by so
that I can get subtotals on my counts. I may be
approaching this completely wrong, and I know just a
little about coding.
 
D

Duane Hookom

Any use of DCount() would be much to slow. To count the number of yes/-1
values in a group section, use
=Sum(Abs([NameOfField]))
 
G

Guest

I don't know why I have to make things so hard. Thank you
sooooo much!
-----Original Message-----
Any use of DCount() would be much to slow. To count the number of yes/-1
values in a group section, use
=Sum(Abs([NameOfField]))


--
Duane Hookom
MS Access MVP
--

I need to count some yes checkmarks in a grouped report.

I can write
=DCount([NameofField],"qryQueryName","[NameofField]=-1")
This counts all the "yes" marks.

I need it to count the yes marks for a particular group.
Something along the line of
=DCount([NameofField],"qryQueryName","[NameofField]=-1 and
[Reports]![rptName]![Whateverfieldthereportisgroupedby]=
[Query]![qryQueryName]! [whateverfieldthereportisgroupedby]

I don't know, but something where the criteria for the
dcount includes what the field the report is grouped by so
that I can get subtotals on my counts. I may be
approaching this completely wrong, and I know just a
little about coding.


.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top