ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   count only visible cells (https://www.excelbanter.com/excel-worksheet-functions/80696-count-only-visible-cells.html)

bnkone

count only visible cells
 
I am using an autofilter on a set of data. I would like to use a countif
field to summarize the visible cells only. So, every time I change the
autofilter I would change the criteria counted.

Any ideas out there?

Peo Sjoblom

count only visible cells
 
Look at the subtotal function in help, it works on visible cells only

=SUBTOTAL(9,A2:A1000)

will sum A2:A1000 and when filtered it will sum only the visible cells in
A2:A1000

=SUBTOTAL(3,A2:A1000)

will count non empty visible cells


--

Regards,

Peo Sjoblom

http://nwexcelsolutions.com



"bnkone" wrote in message
...
I am using an autofilter on a set of data. I would like to use a countif
field to summarize the visible cells only. So, every time I change the
autofilter I would change the criteria counted.

Any ideas out there?




bnkone

count only visible cells
 
Thanks,

Subtotal(3,) did the job.


"Peo Sjoblom" wrote:

Look at the subtotal function in help, it works on visible cells only

=SUBTOTAL(9,A2:A1000)

will sum A2:A1000 and when filtered it will sum only the visible cells in
A2:A1000

=SUBTOTAL(3,A2:A1000)

will count non empty visible cells


--

Regards,

Peo Sjoblom

http://nwexcelsolutions.com



"bnkone" wrote in message
...
I am using an autofilter on a set of data. I would like to use a countif
field to summarize the visible cells only. So, every time I change the
autofilter I would change the criteria counted.

Any ideas out there?






All times are GMT +1. The time now is 02:26 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com