1 Reply Latest reply on Jan 13, 2009 7:36 AM by matthew horn

    multiple axes chart - baseline issue

      Hi all,

      I'm currently working on charts (column, bar, line, ..) with multiple axes (each for one series).

      If negative amount values are shown in a chart, the baselines (for zero values) appears
      on different coordinates/levels.

      As an example see the code listed below:

      <?xml version="1.0"?>
      <mx:Application xmlns:mx=" http://www.adobe.com/2006/mxml">
      import mx.collections.ArrayCollection;
      public var expenses:ArrayCollection = new ArrayCollection([
      {Month:"Jan", Profit:2000, Expenses:15},
      {Month:"Feb", Profit:1000, Expenses:20},
      {Month:"Mar", Profit:1500, Expenses:50},
      {Month:"Apr", Profit:100, Expenses:-10}
      <mx:Panel title="Column Chart">
      <mx:ColumnChart id="myChart" dataProvider="{expenses}" showDataTips="true">
      <mx:CategoryAxis dataProvider="{expenses}" categoryField="Month"/>
      <mx:ColumnSeries xField="Month" yField="Profit" displayName="Profit">
      <mx:LinearAxis id="v1"/>
      <mx:ColumnSeries xField="Month" yField="Expenses"
      <mx:LinearAxis id="v2"/>
      <mx:AxisRenderer placement="left" axis="{v1}"/>
      <mx:AxisRenderer placement="right" axis="{v2}"/>
      <mx:Legend dataProvider="{myChart}"/>

      I'm using Flex Builder 3.0.2 /Flex SDK 3.2.

      Is this is a bug in flex?
      Am i missing something in the mxml/as, or is there a solution or workaround?

      Any hints are highly appreciated.