View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.misc
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default Correct Syntax for Changing Color of Cell Based on Value

: [Blue][0.5]0.0%;[Red][0.25]0.0%;0.0%

(I didn't notice the last sentence of your original post.)


W wrote:

I have a column with percentages in it, and I want to have the color of each
cell change based on values. If the percentage is greater than 50 then I
want Blue. If the percentage is 25 to 50 I want red. If the Percentage
is less than 25 I want black. I guessed at the following syntax for a
Custom number type, but Excel is rejecting this:

[Blue][50]Percentage;[Red][25]Percentage; Percentage

What would be the correct syntax?

A further refinement on this is that I don't want more than one tenth of one
percent precision, so the template would be 00.0%.

--
W


--

Dave Peterson