简体   繁体   中英

Excel: Conditional formatting (colour scale), IF top of column matches a value

I'm a maths teacher and I'm storing my class data in an Excel spreadsheet. Each student occupies a row. Some columns relate to homework completion and they get a certain colour scale formatting. Other columns relate to test scores and they get a different colour scale formatting.

At the moment, when I add a new column for eg another homework exercise, I have to edit the rules manually, so the correct colour scale rule will apply to that particular column. This is quite fiddly and annoying.

I would like to make a single conditional formatting rule for the table that will apply a colour scale highlight to cells based on their values (eg red for 0, yellow for 0.5, green for 1), but ONLY if a cell at the TOP of that column matches a particular value.

To put it another way, I want my column headings to contain indicators for what kind of values go in the column, and I want Excel to apply different colour scale rules to each column based on the indicator at the top.

Is there a way to do this?

(My apologies if this is a duplicate question; I've searched but couldn't find something that connected conditional formatting based on a column header with a colour scale highlighting rule)

Excel's built-in colour scales don't take into account any other factors than the values in the range.

If you want to base the conditional formatting on a combination of factors, you will need to create several conditional formatting rules for the column. You can then copy and paste the format of that column to another column. You can adjust the specific parameters for that column by editing its rules.

Any more detailed advice can only be supplied if you provide a data sample.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM