0 Replies Latest reply on Jun 24, 2009 12:34 AM by lvpho85

    Help, my chart-problem columns


      i used adobe flex build 3.0. Now i had problem about my chart
      i want to create LineChart. I have date. And my date update  minute by minute. My chart  have 16 spaces
      : (8h-9h), (9h-10h)....(22h-23h).


      I want my chart show as the picture blow:








      But Now i don't know how i can like.
      i only created as the picture blow:


      The columns are not standar, not same Identical.Pls See clear the Picture above and blow and Help me
      Now my Code



      <?xml version="1.0"?>
      <!-- http://blog.flexexamples.com/2007/11/19 … ick-marks/ -->
      <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"


                  import mx.charts.HitData;
                  import mx.charts.CategoryAxis;
                  import mx.charts.chartClasses.IAxis;
                  import  mx.charts.GridLines;
                  import mx.collections.ArrayCollection;
                  import mx.graphics.Stroke;
                  import mx.events.ColorPickerEvent;           
                  private function linearAxis_labelFunc(item:Object, prevValue:Object, axis:IAxis):String
                      return currFormatter.format(item);               
                  private function categoryAxis_labelFunc(item:Object, prevValue:Object, axis:CategoryAxis, categoryItem:Object):String
                      return item.valueOf().toString();            
                  private function renderTips(hd:HitData):String
                    return "aaaaaaaaaaaaaa bbbbbbbbbbb";


          <mx:CurrencyFormatter id="currFormatter" precision="2" />  
          <mx:XMLListCollection id="dp12">
                      <quote date="8h" open="90.1" />
                      <quote open="90.1" /> 
                      <quote open="90.1" />                                
                      <quote date="9h"  open="45.5" /> 
                      <quote open="90.1" /> 
                      <quote open="90.1" />         
                      <quote date="10h" open="40.82" />                                           
                      <quote date="11h" open="21.4"  />                
                      <quote date="12h" open="40.41"  />              
                      <quote date="13h" open="40.55"  />
                      <quote date="14h" open="40.18" />             
                      <quote date="15h" open="39.83"  />               
                      <quote date="16h" open="40.22" /> 
                      <quote open="90.1" /> 
                      <quote open="90.1" />                
                      <quote date="17h" open="41.01" /> 
                      <quote date="18h" open="41.21"   />                
                      <quote date="19h" open="32.00" />                 
                      <quote date="20h" open="45.00" />               
                      <quote date="21h" open="29"/>              
                      <quote date="22h" open="30.00" />              
                      <quote date="23h" open="40" />                             
          <mx:LineChart id="lineChart" showDataTips="true" color="black"
              dataProvider="{dp12}"  width="100%" height="100%" alpha="1.0"
              <!-- background elements -->
                  <mx:GridLines id="gridLines" toolTip="Tony adam" direction="both"
                      horizontalTickAligned="true" themeColor="red" alpha="5">                              
                          <mx:SolidColor color="white" alpha="5.0"  />
                          <mx:SolidColor color="white" alpha="5.0" />
              <!-- vertical axis -->
                  <mx:LinearAxis baseAtZero="true"
              <!-- horizontal axis -->
                  <mx:CategoryAxis id="ca"
                          title="Tháng 6 Năm 2009"
              <!-- horizontal axis renderer -->
                  <!--<mx:AxisRenderer axis="{ca}" canDropLabels="false" />-->
                  <mx:AxisRenderer canDropLabels="true" placement="bottom"
                  axis="{ca}" tickPlacement="inside"
                  tickLength="100" minorTickPlacement="inside"
              <!-- series -->
                   <mx:LineSeries yField="@open" displayName="open" xField="@date"
                       interpolateValues="true" form="curve" themeColor="black">
                          <mx:Stroke color="#3333FF" weight="1" alpha="3.1" scaleMode="vertical"/>               
              <!-- series filters -->
                  <mx:Array />