Sumif
How can I add numbers in a row that contain a specific letter? For example,
How can I add 3H to 4H. I just want it to add the numbers containing the letter H. Thanks |
Sumif
Contains means ends with????
=SUM(IF(RIGHT(A1:A3,1)="h",--LEFT(A1:A3,LEN(A1:A3)-1))) or maybe: =SUM(IF(RIGHT(A1:A3,1)="h",--LEFT(A1:A3,LEN(A1:A3)-1)))&"H" This is an array formula. Hit ctrl-shift-enter instead of enter. If you do it correctly, excel will wrap curly brackets {} around your formula. (don't type them yourself.) Adjust the range to match--but you can't use the whole column. JP wrote: How can I add numbers in a row that contain a specific letter? For example, How can I add 3H to 4H. I just want it to add the numbers containing the letter H. Thanks -- Dave Peterson |
Sumif
Hi JP,
If your data is located in range A1:A12 : =SUMPRODUCT(LEFT(A1:A12,1)*(RIGHT(A1:A12,1)="H")) HTH Cheers Carim |
Sumif
This looks like what I am looking to do. However, when I put the function in
I am getting an error. "Carim" wrote: Hi JP, If your data is located in range A1:A12 : =SUMPRODUCT(LEFT(A1:A12,1)*(RIGHT(A1:A12,1)="H")) HTH Cheers Carim |
Sumif
Hi JP,
Give a try to following : =SUMPRODUCT(--Value(LEFT(A1:A12,1))*--(RIGHT(A1:A12,1)="H")) HTH Cheers Carim |
All times are GMT +1. The time now is 11:45 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com