ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   countif again sorry (https://www.excelbanter.com/excel-programming/377589-countif-again-sorry.html)

RobcPettit[_2_]

countif again sorry
 
Sorry, Im not thinking my questions through proply and missing bits of.
Ok if I have in range a1:a13 the letters H or S, doesnt matter on order
or how many of each. Then in b1:b13 I have numbers 1 through to 13. Is
it possible to count how many in b1:b13 are greater that 3 if a1:a13 =
S. For instance
a1 = h b1 = 5
a2 =s b2 = 1
a3 = s b3 = 4
a4 = h b4 = 10
etc therefore only 1 meets my criteria. Id like ti use a worksheet
function if possible.
Regards Robert


Gary Keramidas

countif again sorry
 
i'm no sumproduct expert like bob p, but i'll take a stab

give this a try

=SUMPRODUCT(-(A1:A4="s"),-(B1:B43),B1:B4)

--


Gary


"RobcPettit" wrote in message
ps.com...
Sorry, Im not thinking my questions through proply and missing bits of.
Ok if I have in range a1:a13 the letters H or S, doesnt matter on order
or how many of each. Then in b1:b13 I have numbers 1 through to 13. Is
it possible to count how many in b1:b13 are greater that 3 if a1:a13 =
S. For instance
a1 = h b1 = 5
a2 =s b2 = 1
a3 = s b3 = 4
a4 = h b4 = 10
etc therefore only 1 meets my criteria. Id like ti use a worksheet
function if possible.
Regards Robert




RobcPettit[_2_]

countif again sorry
 
Thankyou for your reply. I added your formula and when i deleted the
last part b1:b4 it worked perfect.

Regards Robert
Gary Keramidas wrote:
i'm no sumproduct expert like bob p, but i'll take a stab

give this a try

=SUMPRODUCT(-(A1:A4="s"),-(B1:B43),B1:B4)

--


Gary


"RobcPettit" wrote in message
ps.com...
Sorry, Im not thinking my questions through proply and missing bits of.
Ok if I have in range a1:a13 the letters H or S, doesnt matter on order
or how many of each. Then in b1:b13 I have numbers 1 through to 13. Is
it possible to count how many in b1:b13 are greater that 3 if a1:a13 =
S. For instance
a1 = h b1 = 5
a2 =s b2 = 1
a3 = s b3 = 4
a4 = h b4 = 10
etc therefore only 1 meets my criteria. Id like ti use a worksheet
function if possible.
Regards Robert




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

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