Count only visible formula results

J

Joe M.

I have a column which has a formula resulting in "X" or blank. I would like
to count the occurences of "X" but only what is visible by the autofilter.
SUBTOTAL counts visible cells regardless of "X or blank and
COUNTIF(H2:H2000,"X") counts all "X" visible and hidden. I only want to count
the results = "X" that are visible. Can someone help?

Thanks,
Joe M.
 
M

Mike H

Try

=SUMPRODUCT(SUBTOTAL(3,OFFSET(H2:H2000,ROW(H2:H2000)-MIN(ROW(H2:H2000)),,1))*(H2:H2000="X"))

Mike
 
J

Joe M.

Mike,

Thanks, it works but I wish I understood this formula. Where can I see it
broken down to better understand how it works?

Thanks,

Joe M.
 

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