Is there any way to highlight the first two rows automatically after applying filters in a worksheet?

wormaji

New Member
Joined
Sep 27, 2018
Messages
22
is there any way that I can coloured the first two rows in a worksheet automatically after applying the filters?This is the overall problem :I have got a sheet with columns like thisitem price criteria1 criteria2I have to frequently filter and note down the price of the first two rows of the item is criteria1 is satisfied ie. it has Yes in front of it and criteria2 is not satisified i.e. it has no in front of it. Similarly, I have to note down the price of the first row of the item when criteria 2 is satisfied that is, it has Yes in front of it and criteria. One is not satisfied that is, it has in front of it.I sometimes end up taking the price of the second and third row instead of the first row. It has to do with my vision disability and I was thinking that if I can highlight the first two rows, then hopefully I won't make mistakes.in summary, we just want the first two rows to be highlighted . Even if the increase keep on changing after applying different filters.Thank you for any inputs
 

Some videos you may like

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.

Fluff

MrExcel MVP, Moderator
Joined
Jun 12, 2014
Messages
38,760
Office Version
365
Platform
Windows
Open the name manager > New > Enter a name (I've called it visible) > in the refers to box enter =GET.CELL(17,INDIRECT("rc",FALSE)) > OK > Close
Then in an unused column on your sheet starting with the first row of data enter =Visible (change to the name you have used) & fill down.
Select your data (excluding any headers) and In conditional formatting enter this formula
=COUNTIF($AF$2:$AF2,">0")<=2
(change column & start row to suit)
Select format colour & give it a go

PS the workbook will need to be saved as a macro enabled workbook
 
Last edited:

Watch MrExcel Video

Forum statistics

Threads
1,095,746
Messages
5,446,253
Members
405,392
Latest member
Steveoaktree1977

This Week's Hot Topics

Top