I found a conditional formula (=(COUNTIF($A$2:$A2,A2)>1) to find duplicates and highlight everything except for the first occurrence. But the opposite is happening. Can someone please tell me what I am doing wrong? The file is attached.
Thank you!
I found a conditional formula (=(COUNTIF($A$2:$A2,A2)>1) to find duplicates and highlight everything except for the first occurrence. But the opposite is happening. Can someone please tell me what I am doing wrong? The file is attached.
Thank you!
Hello
Sorry Couldn't see your file, However, the formula you've provided is designed to highlight everything except for the first occurrence of a duplicate in a column. If you want to reverse the condition to highlight only the first occurrence and not subsequent duplicates, you can adjust the formula. Here's the modified formula:
=COUNTIF($A$2:$A2, A2)=1
In this modified formula:
- `COUNTIF($A$2:$A2, A2)` counts the occurrences of the current value in cell A2 within the range from A2 to the current row.
- `=1` checks if the count is equal to 1, indicating that it's the first occurrence.
Apply this formula as a conditional formatting rule, and it should highlight only the first occurrence of each value in column A. If you want to highlight the entire row based on this condition, make sure to adjust the "Applies to" range in the conditional formatting rule accordingly.