Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
is there a function can count number of word in a cell
example: A B username count kok, hong, Lee chan, NG Ti, Lee after counting A B username count kok, hong, Lee 3 chan, NG 2 Ti, Lee 2 |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
You can count the number of spaces in the cell then add 1:
=LEN(A1)-LEN(SUBSTITUTE(A1,",",""))+1 -- Biff Microsoft Excel MVP "kokhong" wrote in message ... is there a function can count number of word in a cell example: A B username count kok, hong, Lee chan, NG Ti, Lee after counting A B username count kok, hong, Lee 3 chan, NG 2 Ti, Lee 2 |
#3
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
this problem i have settled..this can be found form MIscrosoft help..
the function is : =IF(LEN(TRIM(A1))=0,0,LEN(TRIM(A1))-LEN(SUBSTITUTE(A1," ",""))+1) "kokhong" wrote: is there a function can count number of word in a cell example: A B username count kok, hong, Lee chan, NG Ti, Lee after counting A B username count kok, hong, Lee 3 chan, NG 2 Ti, Lee 2 |
#4
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Using Trim is a very good idea because, accidently, there might have been
typed more than one space between two words. Micky "kokhong" wrote: this problem i have settled..this can be found form MIscrosoft help.. the function is : =IF(LEN(TRIM(A1))=0,0,LEN(TRIM(A1))-LEN(SUBSTITUTE(A1," ",""))+1) "kokhong" wrote: is there a function can count number of word in a cell example: A B username count kok, hong, Lee chan, NG Ti, Lee after counting A B username count kok, hong, Lee 3 chan, NG 2 Ti, Lee 2 |
#5
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
One more that will work ok if the cell is empty:
If the words are separated by spaces: =LEN(TRIM(A1))-LEN(SUBSTITUTE(TRIM(A1)," ",""))+(TRIM(A1)<"") kokhong wrote: is there a function can count number of word in a cell example: A B username count kok, hong, Lee chan, NG Ti, Lee after counting A B username count kok, hong, Lee 3 chan, NG 2 Ti, Lee 2 -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Counting number of occurances of a word | Excel Worksheet Functions | |||
Code for counting number of word strings? | Excel Discussion (Misc queries) | |||
Counting number of times a specific word appears in a single cell | Excel Discussion (Misc queries) | |||
counting the number of times a word appears | Excel Worksheet Functions | |||
Counting the number of times a word appears in a worksheet | Excel Worksheet Functions |