ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Conditional Formatting (https://www.excelbanter.com/excel-programming/323674-conditional-formatting.html)

Geoff Murley

Conditional Formatting
 
I have a sheet with n columns and n rows.

For each row I would like to highlight, in yellow, the 6
cells with the highest values in that row.

I can't think of a way of doing this using the normal
conditional formatting. Is there a VBA solution?

JE McGimpsey

Conditional Formatting
 
CF solution:

Assuming your data starts in Row 1, and n = 10, select A1:J10 with A1
active and use

CF1: Formula is =A1=LARGE($A1:$J1,6)
Format1: <highlight color

Note, if there's a tie for 6th largest in a row, you'll get more than 6
highlighted cells in that row.

In article ,
"Geoff Murley" wrote:

I have a sheet with n columns and n rows.

For each row I would like to highlight, in yellow, the 6
cells with the highest values in that row.

I can't think of a way of doing this using the normal
conditional formatting. Is there a VBA solution?



All times are GMT +1. The time now is 02:33 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com