How to count the number of 'values' in a cell

S

Sandih

Hi

I am after something that seems simple, but I can't figure out a way t
do it.

If I have a single cell containing a list of values seperated by
comma (ie a csv list in a cell), how do I count the number of values.
I figure it must be by counting the commas somehow and then adding on
as the last doesn't have it, but there is no way to tell how many ther
will be.

My cell contents look like this
18911, 18801, 18825, 18482, 18941

so I want to have another cell return the number 5.

Does anyone have any ideas?

Regards
Sand
 
S

Sandih

I think I have the answer I think the following function calculatio
would work....

if
a1 contains 18911, 18801, 18825, 18482, 18941

then the following could give me the number of values in the cell

=LEN(A1)-LEN(SUBSTITUTE(A1,",",""))+
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top