When a conditional formatting rule is overkill, use these VBA procedures to highlight duplicates and then remove the highlighting in Microsoft Excel.
There are many ways to find duplicates in a Microsoft Excel data range—conditional formatting being one of the most commonly used. When the rule is TRUE, the format stays until the condition is FALSE or you remove the rule. However, sometimes, you only want a quick look or count of duplicates; you don’t want a permanent format. Or, more reasonably, users might not be savvy enough to apply a conditional formatting rule. In either case, this article will review VBA code that highlights duplicates in a data range. This article also includes code to remove highlighting from a data range.
SEE: 83 Excel tips every user should…