+ Reply to Thread
Results 1 to 4 of 4

Count the number of words in a cell separated with with two different signs

  1. #1
    Registered User
    Join Date
    05-02-2013
    Location
    Madrid, Spain
    MS-Off Ver
    Excel 2011, Mac
    Posts
    19

    Count the number of words in a cell separated with with two different signs

    Hi guys,

    Can someone help me with a formula that counts the number of words in cells like these:
    CELL1: Aichele & Rauner
    CELL2: Andrus, Sceales, Starke & Sawall
    CELL3: Antonelli, Terry & Wands

    The solutions for which would be 2,4 and 3.

    The problem is that the words are separated with both a comma, and the "&" sign.

    thx!

  2. #2
    Forum Guru :) Sixthsense :)'s Avatar
    Join Date
    01-01-2012
    Location
    India>Tamilnadu>Chennai
    MS-Off Ver
    2003 To 2010
    Posts
    12,770

    Re: Count the number of words in a cell separated with with two different signs

    In A1 Cell
    Aichele & Rauner

    In B1 Cell
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Drag it down...


    If your problem is solved, then please mark the thread as SOLVED>>Above your first post>>Thread Tools>>
    Mark your thread as Solved


    If the suggestion helps you, then Click *below to Add Reputation

  3. #3
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,748

    Re: Count the number of words in a cell separated with with two different signs

    Try this:

    =LEN(TRIM(SUBSTITUTE(A1,"& ","")))-LEN(SUBSTITUTE(TRIM(SUBSTITUTE(A1,"& ",""))," ",""))+1

    The commas are not really a problem unless you have a space in front of them.

    Hope this helps.

    Pete

  4. #4
    Registered User
    Join Date
    05-02-2013
    Location
    Madrid, Spain
    MS-Off Ver
    Excel 2011, Mac
    Posts
    19

    Re: Count the number of words in a cell separated with with two different signs

    Works like a charm! Thank you for the fast response.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1