House of Fusion
Search over 2,500 ColdFusion resources here
  
Home of the ColdFusion Community

Mailing Lists
Home /  Groups /  New York ColdFusion Users Group (NYCFUG)

CFCHART - Setting Pie Chart Colors

  << Previous Post |  RSS |  Sort Oldest First |  Sort Latest First |  Subscribe to this Group Next >> 
Top  |   Reply  |   Original Post  |   RSS Feed  |   Subscribe to this Group
Author:
Jon A. Gilbert
11/04/2007 11:52 AM

I have an application that creates a pie chart based on ratings for each company in the database.   It shows the ratings as a percentage based on factors that are positive, neutral, caution and bad.  The results can range from 100% good to 100% bad or any combination of percentage / types in between. I'm trying to set the pie chart colors to always display the same color for each rating type, but can't see to figure out how to do this. I group and order the output by its value, and have a colorlist in the order that matches that.   However, the problem is that the colors are assigned based on the output, not the value.  If for example, the pie chart has all 4 types, the colors will be perfect.   But, if there is only output for type 1 (positive) and type 4 (bad) the color displayed for bad is the second in the list, rather than the last one. Does anyone know how to set it so that each type is always the same colore (ie. typeID = 1 is green, typeID = 2 is blue, typeID = 3 is yellow, typeID = 4 is red).  

Top  |   Reply  |   Original Post  |   RSS Feed  |   Subscribe to this Group
Author:
Bob/Jules
11/04/2007 05:24 PM

Can't you simply look at the data first and change the color list? If not, maybe you can trick it by making the zero wedges some tiny nonzero value (with blank titling I expect) that won't visually effect the plotting.


<< Previous Thread Today's Threads Next Thread >>

Search nycfug

May 20, 2013

<<   <   Today   >   >>
Su Mo Tu We Th Fr Sa
       1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31   

Designer, Developer and mobile workflow conference