+ Reply to Thread
Results 1 to 14 of 14

Counting words in excel formula

  1. #1
    Registered User
    Join Date
    01-23-2014
    Location
    US
    MS-Off Ver
    Excel 2013
    Posts
    25

    Counting words in excel formula

    I was wondering if there was a formula for counting text in excel I know the basic formula however what I want it to count is as follows. 1-tandem 2-tandem 3-tandem but be able to pick up the numbers in front of the word as well and condense it all into one count. Is this possible? I can set it up to count the word tandem by itself but I am doing a scheduling spreadsheet and have more than one tandem on certain jobs so being able to count up all the trucks under certain names would be beneficial.

  2. #2
    Forum Moderator vlady's Avatar
    Join Date
    09-22-2011
    Location
    Philippines - OLSHCO -Guimba-Nueva Ecija
    MS-Off Ver
    2021
    Posts
    4,361

    Re: Counting words in excel formula

    So in your example 1-tandem 2-tandem 3-tandem what is the answer or total count you expect.
    I think people forget the word "THANK YOU!!!!" Do you still know it???

    There is a little star ( ADD REPUTATION ) below those person who helped you. Click it to say your "PRIVATE APPRECIATION TO THEIR EFFORT ON THEIR CONTRIBUTIONS "

    Regards,
    Vladimir

  3. #3
    Registered User
    Join Date
    01-23-2014
    Location
    US
    MS-Off Ver
    Excel 2013
    Posts
    25

    Re: Counting words in excel formula

    I would like to get the total count of tandems in a field. Cause through the whole work book will be the example above and also the same numbers exponential with other names such as super tandems and super dumps. The idea is that I will be able to keep count of my trucks as I schedule so I don't over book myself. I will try to upload later for some reason I cannot upload my sample sheet.
    Last edited by Here I go again; 01-23-2014 at 10:54 PM.

  4. #4
    Forum Moderator vlady's Avatar
    Join Date
    09-22-2011
    Location
    Philippines - OLSHCO -Guimba-Nueva Ecija
    MS-Off Ver
    2021
    Posts
    4,361

    Re: Counting words in excel formula

    I think it is better to attach a sample workbook.


    To attach a sample workbook. Make sure there is just enough data to make it clear what is needed. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are demonstrated, mock them up manually if needed. Remember to desensitize the data.

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    View Pic

  5. #5
    Registered User
    Join Date
    01-23-2014
    Location
    US
    MS-Off Ver
    Excel 2013
    Posts
    25

    Re: Counting words in excel formula

    For some reason I cannot upload an example format it will not allow me to. I get the spinning beach ball of death when I try to upload. I will try periodically throughout the day.

  6. #6
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,938

    Re: Counting words in excel formula

    This will do the count for you. You can hard-code the word, or reference it...
    =(LEN(A1)-LEN(SUBSTITUTE(A1,"tandem","")))/LEN("tandem")
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  7. #7
    Registered User
    Join Date
    01-23-2014
    Location
    US
    MS-Off Ver
    Excel 2013
    Posts
    25

    Re: Counting words in excel formula

    =COUNTIFS(A3:H154,"1-tandem") this is the formula I use to count my trucks however this formula does not pick up the trucks labeled 2-tandem, 3-tandem, 4-tandem etc. What I would like to find is a formula that could add up all of the tandems with the numbers and dashes included if that is possible. So my outcome count would tell me that (using the example from earlier) I could get a total count of 4 tandems. The formula suggested by FDibbins did not work it gave me back a 0 instead of the 4 that were on my work sheet. Perhaps I entered it wrong?

  8. #8
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: Counting words in excel formula

    This should do it

    =COUNTIF(A3:H154,"*tandem*")
    If you like my answer please click on * Add Reputation
    Don't forget to mark threads as "Solved" if your problem has been resolved

    "Nothing is so firmly believed as what we least know."
    --Michel de Montaigne

  9. #9
    Registered User
    Join Date
    01-23-2014
    Location
    US
    MS-Off Ver
    Excel 2013
    Posts
    25

    Re: Counting words in excel formula

    A lot closer however I do have other trucks labeled 1-super tandem as a different truck that I do not wish to pick up. I there anyway to make it for just the specific tandem? Or will it always pick up all cells with the word tandem in it?

  10. #10
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Counting words in excel formula

    Post some sample data and tell us what result(s) you expect.
    Biff
    Microsoft MVP Excel
    Keep It Simple Stupid

    Let's Go Pens. We Want The Cup.

  11. #11
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: Counting words in excel formula

    Yes,

    =COUNTIF(A3:H154,"*tandem*")-COUNTIF(A3:H154,"*1-super tandem*")

  12. #12
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Counting words in excel formula

    If we're just taking WAG's here's my offering:

    =COUNTIF(A2:A10,"?-tandem")

  13. #13
    Registered User
    Join Date
    01-23-2014
    Location
    US
    MS-Off Ver
    Excel 2013
    Posts
    25

    Re: Counting words in excel formula

    Thank you very much AlKey that was the formula I needed all I had to do was remove the 1- in front of super tandems in order to get it to work thank you very much.

  14. #14
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: Counting words in excel formula

    You're welcome and thank you for your feedback!

    Please mark thread as "Solved" if your issue has been resolved. (Selecting Thread Tools-> Mark thread as Solved).

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] counting occurrence of specific words in another group of words
    By [email protected] in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-02-2021, 07:33 PM
  2. Replies: 1
    Last Post: 11-28-2013, 06:06 PM
  3. [SOLVED] looking formula for Extract Specific WORDs in existing LONG Words
    By santosh226001 in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 08-07-2013, 08:21 AM
  4. Counting words in one column to count words in another column
    By stuart1133 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 12-16-2010, 05:54 AM
  5. counting words
    By Duckie in forum Excel General
    Replies: 2
    Last Post: 01-18-2010, 07:28 PM

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