Figured it out. The approach to use is with actionscript to dynamically
create LineSeries objects, and add them to the LineChart's series array.
I'll post an example.
Tariq Ahmed wrote:
> Hey all, does anyone have a simple example on how to produce multiple
> series in a chart based on an arraycollection?
>
> <mx:LineChart id="linechart"
> dataProvider="{chartData}">
> <mx:horizontalAxis><mx:CategoryAxis
> categoryField="time"/></mx:horizontalAxis>
>
> <mx:series>
> <mx:Repeater id="myRep" dataProvider="{servers}">
> <mx:LineSeries id="info"
> yField="{myRep.currentItem.dataField}" form="curve"
> displayName="{myRep.currentItem.Title}"/>
> </mx:Repeater>
> </mx:series>
> </mx:LineChart>
>
>
> Trying to do something like the above. I get a Type Coercion
> failed...cannot convert mx.core:Repeater to
> mx.charts.charClasses.iChartElement.
>
> Seems like I can't use a repeater that way. What's the proper approach
> here?
>
> Thx!
>
>
--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com
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/