Countif formula

D

Daniel Bonallack

I have values in all cells from A1 to P1.
I'd like a formula (in Q1) which counts how many of jsut
cells E1, J1, and P1 are greater than zero (so my answer
will be either 0,1,2 or 3.

Thanks in advance

Daniel
 
P

Peo Sjoblom

It would be easier if it was some sort of rule like every 5th cell but since
it is 6 steps between J and P it won't work. But since there are so few
cells you can use


=SUM((E1>0),(J1>0),(P1>0))

If there were many cells you could first select them one by one and then do
insert>name>define and give them a name and use a formula like


=SUMPRODUCT(--(LARGE(MyName,ROW(INDIRECT("1:"&COUNT(MyName))))>0))
 
P

Paul

Daniel Bonallack said:
I have values in all cells from A1 to P1.
I'd like a formula (in Q1) which counts how many of jsut
cells E1, J1, and P1 are greater than zero (so my answer
will be either 0,1,2 or 3.

=SUM(E1>0,J1>0,P1>0)
 

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