bagaria
bagaria

Reputation: 123

how do I highlight an excel cell after 2 repetitions of a value in same column?

1----Serial No.
2----123
3----123
4----124
5----125
6----123
7----125
8----128
9----125

In this case cell no. 6 and 9 should be highlighted.

Upvotes: 0

Views: 309

Answers (2)

JosieP
JosieP

Reputation: 3410

assuming your data is in column A, select from row 2 downwards and apply conditional formatting using the formula

=countif($A$1:$A1,A2)>=2

Upvotes: 1

mr.Reband
mr.Reband

Reputation: 2430

If, for example, your data is in column A and starts in cell 1, you can add the following formula to cell B3 and fill down :

=AND(A3=A2, A2=A1)

Then, Autofilter on column B for cells with value TRUE, and highlight the corresponding cells in column A.

Upvotes: 0

Related Questions