The following example shows how you can change the line colors in a LineChart in Flex by setting the lineStroke style in MXML or ActionScript, as seen in the following snippets:
MXML:
<mx:LineSeries id="closeSeries" yField="@close" form="curve" displayName="Close">
<mx:lineStroke>
<mx:Stroke color="haloGreen" weight="2" alpha="0.6" />
</mx:lineStroke>
</mx:LineSeries>
ActionScript:
<mx:LineSeries id="closeSeries" yField="@close" form="curve" displayName="Close" />
...
closeSeries.setStyle("lineStroke", new Stroke(0xFF0000, 2, 0.4));
Full code after the jump.
Continue reading ‘Changing default line colors in a Flex LineChart control’




