Function that counts how many characters are in a range?

Greg Determann

New Member
Joined
Jan 18, 2005
Messages
20
If I have 30 cells and some have only "T" in them and some may have "T C T" in them I need to count how many total characters are listed and it would be great if I could break out the T's and C's counts. Thanks in advance.
 

Excel Facts

Can a formula spear through sheets?
Use =SUM(January:December!E7) to sum E7 on all of the sheets from January through December
Greg Determann said:
If I have 30 cells and some have only "T" in them and some may have "T C T" in them I need to count how many total characters are listed and it would be great if I could break out the T's and C's counts. Thanks in advance.

Limited testing,

=SUMPRODUCT((LEN($A$1:A10)-LEN(SUBSTITUTE($A$1:A10,D1,""))))

For T where D1 houses T

=SUMPRODUCT((LEN($A$1:A10)))

For total characters
 
Upvote 0
Brian's last formula for the total number of characters will count spaces as well as the T's and C's. If you don't want spaces, try:

=SUMPRODUCT(LEN(SUBSTITUTE(A1:A10," ","")))
 
Upvote 0

Forum statistics

Threads
1,222,046
Messages
6,163,588
Members
451,846
Latest member
ajk99

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top