Change the color of the trendline value in FusionCharts v3 for Flash

by filip 14. October 2010 15:07

It seems like FusionCharts does not support changing the color of a trendline via the TRENDVALUES style application.  The color always seems to default to the color of the trendline.

The fix to this issue involves modifying the source of the file (you’ll need the source for fusioncharts to be able to do this).

Search the file for the following line (it should be line 1789):

trendFontObj.color = this.trendLines [i].color;

Right afer this line, paste the following code:

if ( this.styleM.getTextStyle (this.objects.TRENDVALUES).color != undefined )
                    trendFontObj.color = this.styleM.getTextStyle (this.objects.TRENDVALUES).color;

There may be a more “elegant” way of doing this, but the code above will enable you to change the color of trend value lines by using styles in fusioncharts.

Tags: ,

Web Development

Bloodforge Band

Looking for the Bloodforge band site? Click here.

About Filip Stanek

Death Note Pic I'm a developer at ACG in Cincinnati, OH. I like ASP.NET, Flash, and other web technologies, & enjoy playing chess, video games, etc.

Currently playing:


Month List