Microsoft Office Tutorials and References
In Depth Information
Enhancing Reporting with Custom Number Formatting
Applying custom format colors
Have you ever set the formatting on a cell so that negative numbers show up red? If so, you
essentially applied a custom format color. In addition to controlling the look of your numbers with custom
number formatting, you can control their color.
In this example, you format the percentages so that positive percentages show blue with a + symbol,
whereas negative percentages show red with a – symbol. Again, you enter this syntax in the Type
input box shown earlier in Figure 2-12.
[Blue]+0%;[Red]-0%
To apply a color, just enter the color name wrapped in square brackets [ ].
Now, there are only certain colors you can call out by name. You can call out the eight VB colors by
name. These colors make up the first eight colors of the default Excel color palette.
[Black]
[Blue]
[Cyan]
[Green]
[Magenta]
[Red]
[White]
[Yellow]
Blue and Red are the only colors from the 8 VB colors that are viable in a report or
dashboard. The rest of the colors listed are virtually unusable, as they are very unattractive.
Caution
Fortunately, the Excel palette comes with 56 colors that you can call up using a color code. Every
color has a code: The color code for black is 1, the color code for white is 2, and so on.
You can use color codes in your custom number syntax by replacing the named color with the word
COLOR followed by the code.
For example, this syntax formats the percentages so that positive percentages show green with a +
symbol, whereas negative percentages show red with a – symbol.
[COLOR10]+0%;[COLOR3]-0%
Search JabSto ::




Custom Search