Hi Jeff. You should absolutely be able to set the fills array at runtime.
Something like:
mySeries.setStyle("fills", [0xFF0000,0x00FF00,0x0000FF]);
should work. Can you send me a snippet of sample code?
Incidentally ,if you want to make sure it pulls the same colors without
having to change the fills style on the fly, you could insert 0 values for
the missing classifications. Probably not the answer you're looking for,
though, since they would then end up in the legend, which might be a bad
thing.
Ely.
-----Original Message-----
From: [email protected] [mailto:[EMAIL PROTECTED] On
Behalf Of Battershall, Jeff
Sent: Wednesday, May 18, 2005 11:29 AM
To: [email protected]
Subject: [flexcoders] Controlling Pie Chart Colors
Importance: High
I've got a situation where certain pie charts may or may not have
certain classifications won't be represented if there are no values
available in the data provider. The colors are not consistent from chart
to chart - its just pulling the next color from the fill array. So say
on one chart "cash" might appear blue and for another dataprovider it
might appear green.
I'd like to be able to make a certain section of a pie chart ALWAYS have
a certain color. This is easy to do with area charts but I'm finding it
not as easy with pie charts. If I alter the fill array programmatically
that would be good, but in my limited testing I couldn't seem to be able
to do that at runtime.
I tried manually creating a nest array of PieSeries and mapping each one
to a different field and color, but that did not seem to work either.
Jeff Battershall
Application Architect
Dow Jones Indexes
[EMAIL PROTECTED]
(609) 520-5637 (p)
(484) 477-9900 (c)
Yahoo! Groups Links
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/