View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.newusers
Greg Greg is offline
external usenet poster
 
Posts: 331
Default Counting a single value in a cell?

I'm sorry, I should have stated my question more clearly. Is there a way for
me to copy the formula where I would be able to get the results for each row
thereafter? When I added =LEN($B$10)-LEN(SUBSTITUTE($B$10,"-","")) then
copied it to another cell, the result was the same but it should be a
different number.


Thanks,
Greg

"Gary''s Student" wrote:

=LEN(B10)-LEN(SUBSTITUTE(B10,"-",""))

for data in B10
--
Gary''s Student - gsnu200789


"Greg" wrote:

I want to count how often a single value (the dash symbol) occurs in a
single cell than rank it. Showing two examples, AUS-IAH/PTY-IAH/AUS is in
cell A1 and
AUS-ORD-LHR/WAW-LHR-ORD/AUS is cell A2. Cell A1 has 2 dashes and A2 has 4
dashes. Is there a way to do this?

Thank you.