+ Reply to Thread
Results 1 to 5 of 5

Highlight Visible Duplicate Cells

  1. #1
    Valued Forum Contributor realniceguy5000's Avatar
    Join Date
    03-20-2008
    Location
    Fl
    MS-Off Ver
    Excel 2003 & 2010
    Posts
    951

    Highlight Visible Duplicate Cells

    Hi,

    I have included an example workbook to help with my problem.


    What I would like to happen is to auto filter each value in Column "H" Once Auto Filter is engaged then I want to look at the visible cells in Column "G" each cell that is a duplicate in the visible range I want to Highlight those cells.

    Anyone have anything to get me going?

    Thanks as always, Mike
    Attached Files Attached Files

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Highlight Visible Duplicate Cells

    Hi,

    One way would be to use a helper column and conditional formatting. In a helper column, say column I, enter =G5&H5 and copy this down your data.

    Then using the Formula Is option within the conditional formatting in cell G5 enter
    Please Login or Register  to view this content.
    and set the background cell colour as required.

    Now copy G5 and paste special formats down the rest of column G. Hide the helper column I if necessary.

    Regards
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Forum Expert MickG's Avatar
    Join Date
    11-23-2007
    Location
    Banbury,Oxfordshire
    Posts
    2,650

    Re: Highlight Visible Duplicate Cells

    Hi, Here's a Selection change Event .Click "G1".after running your Column "H" Filter.
    Please Login or Register  to view this content.
    Regards Mick

  4. #4
    Valued Forum Contributor realniceguy5000's Avatar
    Join Date
    03-20-2008
    Location
    Fl
    MS-Off Ver
    Excel 2003 & 2010
    Posts
    951

    Re: Highlight Visible Duplicate Cells

    Quote Originally Posted by MickG View Post
    Hi, Here's a Selection change Event .Click "G1".after running your Column "H" Filter.
    Please Login or Register  to view this content.
    Regards Mick
    Hi, I have made some progress but still lacking the duplicate script. I tried your script above but it highlights all the cells. from the filtered group? Also I cant use a worksheet change script as I have many worksheets to run my main script from.

    Here is what I have so far:
    This script will Filter all the values one at a time
    Please Login or Register  to view this content.
    Then I use this Script to find the first visible cell in column "G"
    Please Login or Register  to view this content.
    Now the only part I need to get working is How to find only the duplicate numbers in Column "G" that are visible and Highlight them.

    For example:
    I run my first script and it finds Monday then it will Auto filter by Monday. I then run my find the first visible cell in "G" in this example it is "G20" So if I had a duplicate script it would find "G21" and "G25" and Highlight those 2 cells.

    I searched all over the place for something that may work but haven't gotten any where. Some of the scripts that I found need to look at a selection and since I have only been able to get the first visible cell selected and not the entire range that is visible and have data in them I cant test those.

    Anyway let me know if you can think of anything else that may help in my situation.

    Thank You,Mike

  5. #5
    Valued Forum Contributor realniceguy5000's Avatar
    Join Date
    03-20-2008
    Location
    Fl
    MS-Off Ver
    Excel 2003 & 2010
    Posts
    951

    Re: Highlight Visible Duplicate Cells

    Quote Originally Posted by Richard Buttrey View Post
    Hi,

    One way would be to use a helper column and conditional formatting. In a helper column, say column I, enter =G5&H5 and copy this down your data.

    Then using the Formula Is option within the conditional formatting in cell G5 enter
    Please Login or Register  to view this content.
    and set the background cell colour as required.

    Now copy G5 and paste special formats down the rest of column G. Hide the helper column I if necessary.

    Regards
    Thank You for the help, I was able to use your suggestion to solve my problem,

    Thanks Again, Mike

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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