View Single Post
  #7   Report Post  
Posted to microsoft.public.excel.worksheet.functions
JC-PS JC-PS is offline
external usenet poster
 
Posts: 29
Default How to add (sum) a row cells with letter



"Max" wrote:

Another play to tinker ..
Source data (ie L2.3, S3, W, L3.3 etc) assumed in B2:H2 down
List the 3 letters into J1:L1 : L, S, W (Must be in caps, it's case
sensitive here)
Then paste this into J2's formula bar and press CTRL+SHIFT+ENTER to confirm
the formula (ie array-enter the formula):
=SUM(IF(ISNUMBER(SUBSTITUTE($B2:$H2,J$1,"")+0),SUB STITUTE($B2:$H2,J$1,"")+0))+COUNTIF($B2:$H2,J$1)
Copy J2 across to L2, fill down as far as required
--
Max
Singapore
http://savefile.com/projects/236895
Downloads:17,000 Files:358 Subscribers:55
xdemechanik
---
"JCPS" wrote:
I'm trying to add cells WITH numbers but they have letters
(alphanumerical).
Example: A B C D E Total of sick days
(S) Total vacations (L)
L2.3 S3 W L3.3 - ..... 3
5.5
L1.2 - - - -
1.2
I'd like to sum just numbers of previous cells of A to E and total them at
the last columns.
By the way, if conditional formula may concider like the W letter but
with a specific value like 7.2 and add it to a previos total. The same for S
and L.
Thanks, have been useful. Right now I'm looking for a formula if I have a column for a remark like "No Paid" using a letter W in substitute, but at the same time may discriminate from others like M or F, and give a result of hours used for those kind of license on a column beside this one.


......monday tuesday wednesday ..................Use Hrs---License Letter
.......L3.2.......W...........F................... ................7.2.............W
or
...... -
.........M...........W............................ ......7.2.............M
.................................................. .............(and).7.2.............W this both at the same day (could be on different column).