Adobe Dreamweaver Forums



Last 10 THreads :         Making a photo with rounded corners (Last Post : Linda Rathgeber - Replies : 1 - Views : 2 )           »          Editing spry menu in Contribute (Last Post : ThinkInk - Replies : 2 - Views : 13 )           »          Online shop with barcode scanner (Last Post : Ullitasch - Replies : 0 - Views : 1 )           »          DIV in Table not working. (Last Post : Murray *ACE* - Replies : 5 - Views : 6 )           »          Dreamweaver CS3 Problem on Windows Vista (Last Post : Murray *ACE* - Replies : 15 - Views : 16 )           »          Results from form not coming up (Last Post : Gary White - Replies : 6 - Views : 7 )           »          uploading site (Last Post : Murray *ACE* - Replies : 12 - Views : 13 )           »          Word Document (Last Post : ABCJARED - Replies : 1 - Views : 6 )           »          Re: CF8 keeps crashing (Last Post : crania - Replies : 0 - Views : 1 )           »          CF8 crashes java.lang.OutOfMer moryErronable to createnew native thread (Last Post : crania - Replies : 1 - Views : 2 )           »         


Home Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
User Info Statistics
Go Back   Adobe Dreamweaver Forums > Other Macromedia/Adobe Products > Flex
 
Tags:



Reply
  #1 (permalink)  
Old 10-31-2008, 06:22 PM
kothp00
 
Posts: n/a
Diggs:
Default Grouping the chart data on x-axis

Hi,

I am trying to plot some points on the Plot Chart. I want to show the Text as
my x-axis, so I am using
<mx:horizontalAxis>
<mx:CategoryAxis
id="a1"
dataProvider="{expenses}"
categoryField="Month"
/>
</mx:horizontalAxis>
in my code for x-axis. Now I want to plot all y-axis items under the same
x-axis one if they are from the same 'Month' (used for horizontal axis). If I
try to do this, I am getting more values on the x-axis that have same 'Month'
name. Is there any way I can fix this problem?
Any help would be of great help.
I am also attaching the sample example.


<?xml version="1.0"?>
<!-- charts/DisableAxisLines.mxml -->
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml">
<mx:Script><![CDATA[
import mx.collections.ArrayCollection;
[Bindable]
public var expenses:ArrayCollection = new ArrayCollection([
{Month:"Jan", Profit:2000, Expenses:1500, Amount:450},
{Month:"Feb", Profit:1000, Expenses:200, Amount:600},
{Month:"March", Profit:1500, Expenses:500, Amount:300},
{Month:"Jan", Profit:1000, Expenses:1500, Amount:450},
{Month:"Feb", Profit:2000, Expenses:200, Amount:600},
{Month:"March", Profit:800, Expenses:500, Amount:300},
{Month:"Jan", Profit:200, Expenses:1500, Amount:450},
{Month:"Feb", Profit:100, Expenses:200, Amount:600},
{Month:"March", Profit:150, Expenses:500, Amount:300}
]);
]]></mx:Script>
<mx:Panel title="Plot Chart" width="100%" height="100%">
<mx:PlotChart id="myChart" dataProvider="{expenses}"
showDataTips="true" width="100%" height="100%">
<mx:horizontalAxis>
<mx:CategoryAxis
id="a1"
dataProvider="{expenses}"
categoryField="Month"
/>
</mx:horizontalAxis>
<mx:series>
<mx:PlotSeries
yField="Profit"
displayName="Profit"

/>

</mx:series>
</mx:PlotChart>
</mx:Panel>
</mx:Application>



Reply With Quote
Sponsored Links
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



© Camley Interactive (camley.info) 2008 - all logos and images are copywrite their respective owners.
Proud member of the Camley Interactive Network
All times are GMT. The time now is 09:42 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0 ©2007, Crawlability, Inc.
Cheap Car Insurance - Compare Motor Insurance
Endsleigh Car Insurance Natwest Car Insurance
More Than Car Insurance Norwich Union Car Insurance
Prudential Car Insurance Zurich Car Insurance
Inactive Reminders By Mished.co.uk