Results 1 to 2 of 2

Thread: Formula to highlight duplicate but ignore text/word
Thanks Thanks: 0 Likes Likes: 0

  1. #1
    Board Regular
    Join Date
    Jul 2018
    Location
    Auckland
    Posts
    308
    Post Thanks / Like
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Default Formula to highlight duplicate but ignore text/word

    Hi,

    I have the following formula which almost does what I want it to.

    =SUMPRODUCT(COUNTIF(B8:DG22,B8:DG22)-1)>0

    However, in the range B8:DG22, which is made up of 5-digit numbers and the word "Blank", I want it to tell me if there's any duplicate entries in the range but ignore the word "Blank" in the formula and not count it as part of a duplication.

    Is there a way to amend the code to this?

    Thank you
    Last edited by tlc53; Sep 19th, 2019 at 10:11 PM.

  2. #2
    MrExcel MVP
    Moderator
    Peter_SSs's Avatar
    Join Date
    May 2005
    Location
    Macksville, Australia
    Posts
    41,378
    Post Thanks / Like
    Mentioned
    100 Post(s)
    Tagged
    21 Thread(s)

    Default Re: Formula to highlight duplicate but ignore text/word

    Try this, confirmed with Ctrl+Shift+Enter not just Enter

    =IF(MAX(COUNTIFS(B8:DG22,B8:DG22,B8:DG22,"<>Blank"))>1,"Duplicates","No duplicates")
    Hope this helps, good luck.
    Peter
    Excel 365 - Windows 10
    - Want to help your helpers by posting a small, copyable, screen shot directly in your post? Look here
    - If posting vba code, please use Code Tags - like this [code]Paste code here[/code] - or use the # key in the Reply window
    - Read: Forum Rules, Forum Use Guidelines, & FAQ

Some videos you may like

User Tag List

Tags for this Thread

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •