+ Reply to Thread
Results 1 to 3 of 3

How to search a row for a particular word and add a value of 1 each time

Hybrid View

  1. #1
    Registered User
    Join Date
    09-27-2012
    Location
    Cambridge, England
    MS-Off Ver
    Excel 2010
    Posts
    9

    How to search a row for a particular word and add a value of 1 each time

    Hi there,
    I have a rather basic question that I'm hoping someone may be able to assist with.
    I have a column that contains the word "Trigger" repeatedly (the word appears every 10-15 or so rows). I want to add a number immediately after each of these "Trigger" labels so that the label increases by a value of 1 each time (e.g. Trigger1, Trigger2, Trigger3 etc. etc. all the way up to Trigger900).
    Presumably this is a fairly easy thing to do, but I'm a novice when it comes to Excel!
    Any help greatly appreciated.

  2. #2
    Forum Expert
    Join Date
    03-23-2004
    Location
    London, England
    MS-Off Ver
    Excel 2019
    Posts
    7,082

    Re: How to search a row for a particular word and add a value of 1 each time

    Here's one way
    Assuming your column is A...

    in B1
    =IF(A1="Trigger","Trigger"&COUNTIF(A$1:A1,"Trigger"),"")

    and copy down column B
    Column B is your output with Trigger1, Trigger2 etc
    Regards
    Special-K

    Ensure you describe your problem clearly, I have little time available to solve these problems and do not appreciate numerous changes to them.

  3. #3
    Registered User
    Join Date
    09-27-2012
    Location
    Cambridge, England
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: How to search a row for a particular word and add a value of 1 each time

    Thanks special-K, this has worked nicely!

+ 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. Replies: 2
    Last Post: 04-29-2014, 10:06 AM
  2. Replies: 2
    Last Post: 08-05-2013, 04:45 PM
  3. Replies: 1
    Last Post: 01-25-2011, 10:50 PM
  4. How to search for a word in a column and have entire row opaque once word is found
    By copleyr in forum Excel Programming / VBA / Macros
    Replies: 17
    Last Post: 09-04-2009, 07:11 PM
  5. search for a specific word and copy the word and the preceeding words until a comma
    By DHANANJAY in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 12-31-2005, 09:10 AM

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