ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Count If Function (https://www.excelbanter.com/excel-worksheet-functions/23220-count-if-function.html)

Michele

Count If Function
 
I am trying to write a formula to return a count if cell a1 equals "value a"
and cell a2 is not blank. I have tried various combinations of countif,
if(and..., counta, and count formulas with no success! Can anyone assist me
with creating a formula?

Thanks-
Michele

JulieD

Hi Michele

one option
=SUMPRODUCT(--(A1="a"),--(A2<""))

check out
http://www.xldynamic.com/source/xld.SUMPRODUCT.html

for details on how this function works
--
Cheers
JulieD
check out www.hcts.net.au/tipsandtricks.htm
....well i'm working on it anyway
"Michele" wrote in message
...
I am trying to write a formula to return a count if cell a1 equals "value
a"
and cell a2 is not blank. I have tried various combinations of countif,
if(and..., counta, and count formulas with no success! Can anyone assist
me
with creating a formula?

Thanks-
Michele




bj

try
=sumproduct(--(A1:Z1="value a"),--(A2:Z2<""))
assuming you want rows checked

"Michele" wrote:

I am trying to write a formula to return a count if cell a1 equals "value a"
and cell a2 is not blank. I have tried various combinations of countif,
if(and..., counta, and count formulas with no success! Can anyone assist me
with creating a formula?

Thanks-
Michele


Michele

Thank you both so much! It worked! Now my manager can get off my back :)

"bj" wrote:

try
=sumproduct(--(A1:Z1="value a"),--(A2:Z2<""))
assuming you want rows checked

"Michele" wrote:

I am trying to write a formula to return a count if cell a1 equals "value a"
and cell a2 is not blank. I have tried various combinations of countif,
if(and..., counta, and count formulas with no success! Can anyone assist me
with creating a formula?

Thanks-
Michele



All times are GMT +1. The time now is 07:50 AM.

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