View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Alco Engineer[_2_] Alco Engineer[_2_] is offline
external usenet poster
 
Posts: 7
Default Counting characters within a cell

Thanks Sheeloo, but it isn't a text cell.

Instead the cell is an addition formula (i.e =125+55+36) and displays 216 as
the result.

I need to be able to determine how many numbers have been used to calculate
that result. Is there any way I can do this?

"Sheeloo" wrote:

If A1 contains 125+65+122+35 as text (not a formula =125+65+122+35 showing
cell value as 347) then following in B1 will give the count of + symbol plus
1;
=LEN(A1)-LEN(SUBSTITUTE(A1,"+",""))+1

"Alco Engineer" wrote:

In order to help update an existing spreadsheet, I want to be able to count
either the number of numbers in a given cells, or alternatively the number
off addition signs.

i.e.
A1 =125+65+122+35

In A2 I'd like to be able to count either the number of numbers(eg. 4
numbers in this example where 125 is a single number), or the number of +'s
(and then add one) so that I can calculate the delivery fees based on the
number of deliveries (which is what the cell represents)

Changing the spreadsheet to hold all the data in seperate cells while being
easier from this point of view is not an option.

Thanks