text value of a cell

H

Harald Staff

Please share with us where ideas like that come from.
Sumif is, as its name indicates, supposed to return a sum. Sums are almost
always numbers.

HTH. Best wishes Harald
 
R

Ragdyer

If you mean that you wish to total number values that are text formatted,
where Sumif() doesn't recognize them as numbers, and returns a 0, you could
try SumProduct.

The *asterisk* form of Sumproduct will recognize text numbers, where as the
unary form will not.

If A1:A50 are "text" numbers,
=SUMPRODUCT((B1:B50="CAT")*A1:A50)
*Will* total Column A

Where as,
=SUMPRODUCT(--(B1:B50="CAT"),A1:A50)
Will *not*!
 
R

Ragdyer

BUT ... I guess it can be coerced, with an *additional* set of unarys:

=SUMPRODUCT(--(B1:B50="CAT"),--A1:A50)
 
B

Bob Phillips

The *asterisk* form of Sumproduct will recognize text numbers, where as the
unary form will not.

If A1:A50 are "text" numbers,
=SUMPRODUCT((B1:B50="CAT")*A1:A50)
*Will* total Column A

Where as,
=SUMPRODUCT(--(B1:B50="CAT"),A1:A50)
Will *not*!

=SUMPRODUCT(--(B1:B50="CAT"),--(A1:A50))

But I think the OP just wants

=SUMPRODUCT(--(A1:A50))
 
R

Ragdyer

With the "if" in the OP, I do believe that some sort of condition is
supposed to be met.

We're both going under the assumption that we understood the OP in the first
place.
Maybe Harald was correct, and (s)he just misstated the question at the
outset.<g>
 
B

Bob Phillips

Ragdyer said:
BUT ... I guess it can be coerced, with an *additional* set of unarys:

=SUMPRODUCT(--(B1:B50="CAT"),--A1:A50)

You beat me to it by minutes <g>
 
Top