Count on report, based on report, not query.

G

Guest

I have a report that is based on a query. My report is grouped and I only
want the count on my footer to count what is shown on the report, not the
actual count from my query. I am trying to count cities. I have nineteen
records, which is what the count is giving me, however, grouped there are
only eight cities due to duplicate fields.

I used: =count([ATM CITY]) This retrieved a count of 19 instead of the
eight that show on the report.

I also tried: =count(reports![report1].[ATM CITY] This retrieved 0.

Any help would be appreciated!
 
M

Marshall Barton

J. Scadlock said:
I have a report that is based on a query. My report is grouped and I only
want the count on my footer to count what is shown on the report, not the
actual count from my query. I am trying to count cities. I have nineteen
records, which is what the count is giving me, however, grouped there are
only eight cities due to duplicate fields.


Make sure your group has either a header or footer section
for the City field. Then add a text box named txtCityCount
to the header or footer and set its control source to =1 and
its RunningSum property to Over All.

A report footer text box can then display the number of
cities by using the simple expression =txtCityCount
 

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

Top