Hey Mike,

<mx:CartesianChart id="chart"
                          dataProvider="{_localChartData}"
secondDataProvider="{_localChartData}"
                          series="{_firstSeriesArray}"
secondSeries="{_secondSeriesArray}">

<mx:Script>
       <![CDATA[
           [Bindable] private var _firstSeriesArray:Array;
           [Bindable] private var _secondSeriesArray:Array;


           private function createSeries():void
           {
                   _firstSeriesArray = new Array();
                   //LEFT AXIS
                   var leftSeriesItem:ColumnSeries = new ColumnSeries();
                   leftSeriesItem.yField = "yFieldName";
                   leftSeriesItem.displayName = "yFieldName";
                   _firstSeriesArray[0] = leftSeriesItem;

                       _secondSeriesArray = new Array();
                       var rightSeriesItem:LineSeries = new LineSeries();
                       rightSeriesItem.yField = "yFieldName";
                       rightSeriesItem.displayName = "yFieldDisplayName";
                       _secondSeriesArray[0] = rightSeriesItem;
           }

]]>
</mx:Script>


Perhaps you're missing the secondDataProvider property?


Brendan




On 2/23/07, leds usop <[EMAIL PROTECTED]> wrote:

  a code post will help :)

--- mgrayfmr <[EMAIL PROTECTED] <mgrayfmr%40yahoo.com>> wrote:

> Hey Gang -
>
> Has anyone had any experience with dynamically
> adding a second series
> to a chart using actionscript 3.0 ?
> Using a LineChart object I have been dynamically
> creating new
> LineSeries under the linechart's series with no
> problem.
> I am not having luck adding a second series though.
> The data is fine, it just won't display a second
> series.
> To test, I added my secondSeries data to the primary
> series, and it
> displays (but realtive to the wrong Y axis,
> obviously).
>
> If anyone has any ideas, I would appreciate it.
> If I find a solution, I'll post it here as well.
>
> Thanks,
> Mike
>
>

__________________________________________________________
Sucker-punch spam with award-winning protection.
Try the free Yahoo! Mail Beta.
http://advision.webevents.yahoo.com/mailbeta/features_spam.html



--
Brendan Meutzner
Stretch Media - RIA Adobe Flex Development
[EMAIL PROTECTED]
http://www.stretchmedia.ca

Reply via email to