+ Reply to Thread
Results 1 to 6 of 6

Highlight a cell if another is selected (second serving)

  1. #1
    Registered User
    Join Date
    03-13-2009
    Location
    Bangkok, Thailand
    MS-Off Ver
    Excel 2003
    Posts
    8

    Highlight a cell if another is selected (second serving)

    Hello to you all,

    Yesterday, I asked whether it was possible to make all the cells containing the name Smith turn yellow whenever I select A1 and revert to no highlight when I deselect it. User BMV answered with a sample file that worked great but only when Smith was the only word in the cell text.

    But what if Smith is only part of the cell content ("John Smith", "Smith & Co", "Smith & Wesson", "WH Smith"...) ?

    Thanks for any reply

  2. #2
    Forum Expert Mumps1's Avatar
    Join Date
    10-10-2012
    Location
    Toronto, Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,084

    Re: Highlight a cell if another is selected (second serving)

    Can you post the sample file which includes the current macro?
    You can say "THANK YOU" for help received by clicking the Star symbol at the bottom left of the helper's post.
    Practice makes perfect. I'm very far from perfect so I'm still practising.

  3. #3
    Registered User
    Join Date
    03-13-2009
    Location
    Bangkok, Thailand
    MS-Off Ver
    Excel 2003
    Posts
    8

    Re: Highlight a cell if another is selected (second serving)

    Quote Originally Posted by Mumps1 View Post
    Can you post the sample file which includes the current macro?
    Here it is (see conditional formatting)...
    Attached Files Attached Files

  4. #4
    Forum Expert Mumps1's Avatar
    Join Date
    10-10-2012
    Location
    Toronto, Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,084

    Re: Highlight a cell if another is selected (second serving)

    Try replacing the conditional formatting formulas with: =SEARCH("Jon",A1) and =SEARCH("Smith",A1)

  5. #5
    Registered User
    Join Date
    03-13-2009
    Location
    Bangkok, Thailand
    MS-Off Ver
    Excel 2003
    Posts
    8

    Re: Highlight a cell if another is selected (second serving)

    Works perfectly! Thanks a lot

  6. #6
    Forum Expert Mumps1's Avatar
    Join Date
    10-10-2012
    Location
    Toronto, Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,084

    Re: Highlight a cell if another is selected (second serving)

    My pleasure.

+ 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. Highlight a cell if another is selected
    By Olopocram in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-25-2020, 10:30 PM
  2. Highlight a cell if another is selected
    By Olopocram in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 05-25-2020, 12:41 AM
  3. Highlight row and/or column when cell is selected
    By dgibney in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-26-2017, 03:44 AM
  4. Highlight row and column of selected cell
    By SwissExcel in forum Excel General
    Replies: 8
    Last Post: 09-14-2016, 06:46 AM
  5. Highlight cell if row is selected?
    By SneakyPiglet in forum Excel General
    Replies: 1
    Last Post: 10-04-2013, 06:55 PM
  6. Replies: 4
    Last Post: 09-03-2013, 02:35 PM
  7. How to highlight the selected cell
    By jeffreykeefer in forum Excel General
    Replies: 2
    Last Post: 03-03-2008, 12:33 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