Excel Color – Order of Application (Hierarchy)

Have you ever wondered why Excel, on occasion, will or will not color a cell according to your instructions?  The reason may lie in the order by which Excel applies colors.

Excel applies colors in layers.  These layers are comprised of three criteria:

  1. Colors automatically applied via the implementation of a Data Table
  2. Colors manually applied by the user
  3. Colors automatically applied via the implementation of Conditional Formatting

When using Data Tables (located on the HOME ribbon), colors are applied and controlled by the Data Table feature.  This is a great way to make tables look beautiful as well as maintaining those colors when user’s manipulate the data; i.e. add/remove rows or sort the data.  These colors are assigned first and are easily overwritten by the following two methods.

SNAGHTML16902d2

When a user selects a cell (or set of cells) and uses the Cell Fill tool, this will apply the selected color.  If the user’s cell selection currently displays color assigned by a Data Table, that color will be replaced by the new user-defined color.  User-Defined colors are assigned second and are easily overwritten by the third method.

SNAGHTML16ca713

When using Conditional Formatting (located on the HOME ribbon), colors are applied and controlled by the rules set forth in the Conditional Formatting tool.  Rules are applied in order that the rules are listed from top to bottom.  If more than one rule applies to the same cell, the last qualifying rule is the color to be displayed.  A qualifying color can be made to “stay” even if a later rule qualifies by enabling the “Stop If True” checkbox listed to the right of the applicable rule.

image

A Practical Example

Suppose we have a table of information and we wish to change it cosmetically based on the following criteria:

  • Use the Data Table feature to apply a blue color scheme with banded-gray rows
  • Manually select certain rows and paint those rows with a yellow fill
  • Use the Conditional Formatting feature to change the cell background color to red for every cell with a sale greater than $1,500

Original Data

SNAGHTML17ece1b

Layer 1 – Data Table color assignments

SNAGHTML1803d6a

Layer 2 – User-Defined color assignments

SNAGHTML181d64a

Layer 3 – Conditional Formatting color assignments

SNAGHTML183016c

Stack them atop one another like so…

Excel Color Layers v3.1

…and the resulting color output is as follows.

Excel Color Composite