use the secondHorizontalAxisRenderer and secondVerticalAxisRenderer properties to control the appearance of the secondary axis : Column Chart Axis « Chart « Flex






use the secondHorizontalAxisRenderer and secondVerticalAxisRenderer properties to control the appearance of the secondary axis

use the secondHorizontalAxisRenderer and secondVerticalAxisRenderer properties to control the appearance of the secondary axis
            
<!--
Code from Flex 4 Documentation "Using Adobe Flex 4".

This user guide is licensed for use under the terms of the Creative Commons Attribution 
Non-Commercial 3.0 License. 

This License allows users to copy, distribute, and transmit the user guide for noncommercial 
purposes only so long as 
  (1) proper attribution to Adobe is given as the owner of the user guide; and 
  (2) any reuse or distribution of the user guide contains a notice that use of the user guide is governed by these terms. 
The best way to provide notice is to include the following link. 
To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/3.0/

-->
<!-- charts/MultipleAxesMultipleRenderers.mxml -->
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" width="600"
  height="600">
  <mx:Script>
    [Bindable]
    public var SMITH:Array = [
      {date: "22-Aug-05", close: 45.87},
      {date: "23-Aug-05", close: 45.74},
      {date: "24-Aug-05", close: 45.77},
      {date: "25-Aug-05", close: 46.06},
      ];
    [Bindable]
    public var DECKER:Array = [
      {date: "22-Aug-05", close: 157.59},
      {date: "23-Aug-05", close: 157.3},
      {date: "24-Aug-05", close: 156.71},
      {date: "25-Aug-05", close: 156.88},
      ];
    </mx:Script>
  <mx:Panel title="Chart" width="400" height="400">
    <mx:ColumnChart id="mychart" dataProvider="{SMITH}"
      secondDataProvider="{DECKER}" showDataTips="true" height="250"
      width="350">
      <mx:horizontalAxis>
        <mx:CategoryAxis dataProvider="{SMITH}"
          categoryField="date" />
      </mx:horizontalAxis>
      <mx:verticalAxis>
        <mx:LinearAxis minimum="30" maximum="50" />
      </mx:verticalAxis>
      <mx:series>
        <mx:ColumnSeries dataProvider="{SMITH}" xField="date"
          yField="close" displayName="SMITH" />
      </mx:series>
      <mx:secondVerticalAxis>
        <mx:LinearAxis minimum="150" maximum="170" />
      </mx:secondVerticalAxis>
      <mx:verticalAxisRenderer>
        <mx:AxisRenderer placement="right"
          tickPlacement="inside">
          <mx:axisStroke>
            <mx:Stroke color="#CC6699" weight="1" />
          </mx:axisStroke>
          <mx:tickStroke>
            <mx:Stroke color="#CC0099" weight="1" />
          </mx:tickStroke>
          <mx:minorTickStroke>
            <mx:Stroke color="#990066" weight="1" />
          </mx:minorTickStroke>
        </mx:AxisRenderer>
      </mx:verticalAxisRenderer>
      <mx:secondVerticalAxisRenderer>
        <mx:AxisRenderer placement="left"
          tickPlacement="inside">
          <mx:axisStroke>
            <mx:Stroke color="#000080" weight="1" />
          </mx:axisStroke>
          <mx:tickStroke>
            <mx:Stroke color="#000160" weight="1" />
          </mx:tickStroke>
          <mx:minorTickStroke>
            <mx:Stroke color="#100040" weight="1" />
          </mx:minorTickStroke>
        </mx:AxisRenderer>
      </mx:secondVerticalAxisRenderer>
      <mx:secondSeries>
        <mx:LineSeries dataProvider="{DECKER}" xField="date"
          yField="close" displayName="DECKER" />
      </mx:secondSeries>
    </mx:ColumnChart>
  </mx:Panel>

</mx:Application>

   
    
    
    
    
    
    
    
    
    
    
    
  








Related examples in the same category

1.horizontal Axis Renderer for ColumnCharthorizontal Axis Renderer for ColumnChart
2.Axis Renderer for ColumnChartAxis Renderer for ColumnChart
3.vertical Axis Renderer for ColumnChartvertical Axis Renderer for ColumnChart
4.Create a ColumnChart control with the default axis locations (bottom and left).Create a ColumnChart control with the default axis locations (bottom and left).
5.Column Chart Axis LabelColumn Chart Axis Label
6.Set Axis label for Column chartSet Axis label for Column chart
7.Customize horizontalAxisRenderer and AxisRendererCustomize horizontalAxisRenderer and AxisRenderer
8.Customize axisStrokeCustomize axisStroke
9.The following example removes tick marks from the horizontal axis:The following example removes tick marks from the horizontal axis:
10.Date Time Axis RangeDate Time Axis Range
11.Adding axis titlesAdding axis titles
12.Set LinearAxis, and formats the values to include a dollar sign and a thousands separator.Set LinearAxis, and formats the values to include a dollar sign and a thousands separator.
13.Create two functions that access complex data for both the axis and the seriesCreate two functions that access complex data for both the axis and the series
14.Remove tick marks from the horizontal axisRemove tick marks from the horizontal axis