Home Tutorials Forums Articles Blogs Movies Library Employment Press

Go Back   ActionScript.org Forums > Flex > Flex 2, 3 & 4

Reply
 
Thread Tools Rate Thread Display Modes
Old 03-27-2007, 09:19 PM   #1
abeall
Senior Member
 
Join Date: Feb 2006
Location: Washington, DC
Posts: 2,796
Send a message via AIM to abeall
Default How did Adobe animate the charting components?

I'm new to Flex. New as in we just bought FB2 today and I started my first Flex project ever. I've used AS1/2 with the Flash IDE for years, and I know a bit of AS3, but mxml is a beast I have not had to face yet. At any rate, I'm making a small app for our company to display reports, using Flex Builder 2 and the Charting components. Something that caught my eye was how the graphs animate, as in Adobe's "dashboard" example:

http://examples.adobe.com/flex2/inpr...dashboard.html

I figured this was a native feature when the data was set(dataProvider) for a charting component, but it apparently is not, as my graphs never animate when data is updated. How was this animation of the charts done? I've looked through the source, but as I'm quite fresh to the Flex framework(FFF™) I was unable to find anything that looked like it was the answer. Any help from you Flexers would be appreciated.
abeall is offline   Reply With Quote
Old 03-27-2007, 09:23 PM   #2
senocular
six eyes
 
senocular's Avatar
 
Join Date: Jan 2003
Location: San Francisco, CA (USA)
Posts: 7,875
Send a message via ICQ to senocular Send a message via AIM to senocular Send a message via MSN to senocular Send a message via Yahoo to senocular
Default

Right-click on that example and select "View Source"
__________________
(6)
senocular is offline   Reply With Quote
Old 03-27-2007, 09:45 PM   #3
abeall
Senior Member
 
Join Date: Feb 2006
Location: Washington, DC
Posts: 2,796
Send a message via AIM to abeall
Default

Indeed, I've looked through each mxml file several times and don't see anything, nor do I really know what I'm looking for

PS - these smilies are the whack!
abeall is offline   Reply With Quote
Old 03-28-2007, 04:58 PM   #4
dr_zeus
Feathers
 
dr_zeus's Avatar
 
Join Date: Mar 2005
Location: Silicon Valley
Posts: 1,999
Default

In RegionDetail.mxml:

Code:
showDataEffect="{interpolate}"
"interpolate" is defined in RevenueTimeline:

Code:
<mx:SeriesInterpolate id="interpolate" elementOffset="10"/>
__________________
Josh Tynjala | Feathers
dr_zeus is offline   Reply With Quote
Old 03-28-2007, 05:00 PM   #5
abeall
Senior Member
 
Join Date: Feb 2006
Location: Washington, DC
Posts: 2,796
Send a message via AIM to abeall
Default

[EDIT] Wow, incredible timing, zeus. I bet it didn't take you a day and a half to figure that out, like it took me [/EDIT]

Alright, I figured it out! First you create a tag which represents an effect:
<mx:SeriesInterpolate id="dataEffect" duration="1000" minimumElementDuration="200" elementOffset="0" />

Then you can set a few effect attributes, like the 'showDataEffect':

<mx:ColumnSeries showDataEffect="dataEffect" xField="date" displayName="{dataDisplayName}" yField="{dataField}"/>

...mxml is weird, but that's some sweet, flashy, goodness! I can't imagine what went into making the Flex class library/framework.
abeall is offline   Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Why do components take so long to appear on stage? xbrotherx Components 3 06-21-2006 04:00 PM
flash charting components sircutbreaker Components 0 05-11-2006 02:48 PM
selling charting components LittleToad Components 0 03-01-2005 04:23 AM
New Charting Components for FMX2004 blackmamba2 Components 2 12-07-2004 09:07 AM
Macromedia Charting Components Supa-T Components 0 04-05-2004 04:38 PM


All times are GMT. The time now is 11:51 PM.

///
Follow actionscriptorg on Twitter

 


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.