+ Reply to Thread
Results 1 to 4 of 4

Conditional formatting one range containing text from another range

Hybrid View

  1. #1
    Registered User
    Join Date
    12-06-2012
    Location
    England
    MS-Off Ver
    Excel 2003
    Posts
    2

    Conditional formatting one range containing text from another range

    Hi all,

    I am having a problem with conditional formatting on a range. The first range is the one in which the formatting is being placed, and consists of descriptions, ie. "256276727 Joe Bloggs" or "25627 Joe Bloggs". The second range consists of numbers such as "25627".

    What I wish to do is have every cell from range one that has any number from range two appear within it be placed in a certain colour. I have tried numerous formulas such as countif with wildcards, search functions etc, but can't seem to get to the bottom of how to accomplish this, match doesn't work as the cells in range one consist of more text than just second range numericals. Any help would be great! Many thanks!

  2. #2
    Forum Contributor
    Join Date
    12-22-2010
    Location
    Rio, Brazil
    MS-Off Ver
    Excel 2010, 2016
    Posts
    209

    Re: Conditional formatting one range containing text from another range

    Maybe this

    Data Range
    A
    B
    C
    1
    Range1
    List
    2
    256276727 Joe Bloggs
    25627
    3
    25627 Joe Bloggs
    12345
    4
    blah 12345 blah
    5
    bleh 123456

    Select A2:A5
    Home > Conditional Formatting > New Rule > Use a formula to determine which cells to format

    insert this formula
    =SUM(--ISNUMBER(SEARCH(" "&MyList&" "," "&A2&" ")))
    pick the format you want

    Where MyList is a named range (C2:C3 in the example above)
    Marcelo Branco

  3. #3
    Registered User
    Join Date
    12-06-2012
    Location
    England
    MS-Off Ver
    Excel 2003
    Posts
    2

    Re: Conditional formatting one range containing text from another range

    Ah, thank you very much, that has done just as intended!
    You are a god send.

  4. #4
    Forum Contributor
    Join Date
    12-22-2010
    Location
    Rio, Brazil
    MS-Off Ver
    Excel 2010, 2016
    Posts
    209

    Re: Conditional formatting one range containing text from another range

    Quote Originally Posted by thedeakster View Post
    Ah, thank you very much, that has done just as intended!
    You are a god send.
    You are welcome and thanks for the feedback

+ 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: 3
    Last Post: 08-13-2013, 09:44 AM
  2. [SOLVED] conditional formatting high numbers within text/numerical range
    By Mike Brewer in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 04-24-2013, 11:53 AM
  3. Replies: 2
    Last Post: 04-12-2013, 09:30 AM
  4. Conditional Formatting - Grey Out and Lock A range based on a cell value in that range
    By Excelgnome in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-14-2012, 07:31 PM
  5. [SOLVED] Conditional Formatting (How to format a range depending on another range)
    By Josh Rogers in forum Excel General
    Replies: 2
    Last Post: 10-06-2005, 03:05 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