+ Reply to Thread
Results 1 to 9 of 9

Conditional formatting by matching part characters of cell with another cell

  1. #1
    Forum Contributor
    Join Date
    02-27-2009
    Location
    Chennai, India
    MS-Off Ver
    Excel 2013
    Posts
    327

    Conditional formatting by matching part characters of cell with another cell

    Ref attachment TEST222.xlsx

    In sheet "TWO" conditional formatting is used to match last 5 characters of A column with sheet "ONE"'s A column's last 5 characters.

    But I need to match last 5 characters of A column with sheet "ONE"'s A column's "any five characters".

    for example when looking for 53246 it should highlight 18231053246 as well as 53246182302.

    How to do this. Thanks in advance.
    Attached Files Attached Files
    Ask me how to hate XL.

  2. #2
    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,926

    Re: Conditional formatting by matching part characters of cell with another cell

    Try this as teh CF rule instead...
    =MATCH("*"&RIGHT(A1,5)&"*",ONE!$A$1:$A$251,0)
    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

  3. #3
    Forum Contributor
    Join Date
    02-27-2009
    Location
    Chennai, India
    MS-Off Ver
    Excel 2013
    Posts
    327

    Re: Conditional formatting by matching part characters of cell with another cell

    Also I require one more solution, i forgot to mention.

    I need to find and highlight "exact matching" for those cells too. Please help on this also.

  4. #4
    Forum Expert tim201110's Avatar
    Join Date
    10-23-2011
    Location
    Russia
    MS-Off Ver
    2016, 2019
    Posts
    2,357

    Re: Conditional formatting by matching part characters of cell with another cell

    =sumproduct(--isnumber(find(mid(one!a1,row(indirect("1:"&len(one!a1))),1),two!$a$1:$a$3144)))>=5

  5. #5
    Forum Contributor
    Join Date
    02-27-2009
    Location
    Chennai, India
    MS-Off Ver
    Excel 2013
    Posts
    327

    Re: Conditional formatting by matching part characters of cell with another cell

    Quote Originally Posted by tim201110 View Post
    =sumproduct(--isnumber(find(mid(one!a1,row(indirect("1:"&len(one!a1))),1),two!$a$1:$a$3144)))>=5
    i think it is not working.

  6. #6
    Forum Contributor
    Join Date
    02-27-2009
    Location
    Chennai, India
    MS-Off Ver
    Excel 2013
    Posts
    327

    Re: Conditional formatting by matching part characters of cell with another cell

    Quote Originally Posted by jilaba View Post
    Also I require one more solution, i forgot to mention.

    I need to find and highlight "exact matching" for those cells too. Please help on this also.
    As of now, i need to get solution for this.

  7. #7
    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,926

    Re: Conditional formatting by matching part characters of cell with another cell

    did you try post 2?

  8. #8
    Forum Contributor
    Join Date
    02-27-2009
    Location
    Chennai, India
    MS-Off Ver
    Excel 2013
    Posts
    327

    Re: Conditional formatting by matching part characters of cell with another cell

    Quote Originally Posted by FDibbins View Post
    did you try post 2?
    I saw this now only. It is working great. Thanks. Also I need to find and highlight "exact matching" for those cells too. Please help on this also.

  9. #9
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,531

    Re: Conditional formatting by matching part characters of cell with another cell

    To 'exactly match' the entire string of numbers modify Ford's formula so that it reads: =MATCH(A1,ONE!$A$1:$A$251,0)
    Let us know if you have any questions.
    Consider taking the time to add to the reputation of everybody that has taken the time to respond to your query.

+ 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] Conditional formatting by matching part characters of cell
    By jilaba in forum Excel General
    Replies: 9
    Last Post: 04-05-2017, 01:57 PM
  2. Replies: 6
    Last Post: 02-05-2017, 03:44 AM
  3. Replies: 1
    Last Post: 03-06-2014, 07:14 PM
  4. Replies: 5
    Last Post: 01-14-2013, 01:26 PM
  5. conditional formatting based on PART of a cell value
    By agni452 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-02-2012, 05:37 AM
  6. [SOLVED] conditional formatting to count characters in a cell
    By juliemad in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-31-2012, 04:03 PM
  7. Conditional Formatting - part of cell only
    By RobDDrums in forum Excel General
    Replies: 1
    Last Post: 01-09-2006, 07:15 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