View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default Sum only numbers?!

Assume values are in A1:E1 and non numeric entries start with a single
letter.
=SUM(IF(ISNUMBER(A1:E1),A1:E1,RIGHT(A1:E1,LEN(A1:E 1)-1)*1))
Entered with Ctrl+Shift+enter rather than just enter because this is an
array formula.

--
Regards,
Tom Ogilvy

"dove_g" wrote in message
...
Row in excel have following values:

9 12 P4 3 P1


In sum I must get this results:

SUM (9 + 12 + 4 + 3 + 1 ) = 27
SUM P (1 + 1) = 2

Is that possibe, I have try few formulas without success. Problem is
only how to calculate (SUM) all this.

Thank you.


P.S.
I have only letter P, on the left side, so I can use LEFT(x,1)="P".