Another charting option: XML/SWF Charts

A few weeks ago I blogged about an alternative to ColdFusion's built in charts, Google's Chart API. This week I discovered another alternative, XML/SWF Charts. This isn't a free option, but they have a free license with limitations and the price for a "full" copy is only 45 bucks for a single domain. It works pretty easy too.

You basically drop in a set of SWF files and then call the SWF and point to a XML file:

<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
   codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0"
   WIDTH="400"
   HEIGHT="250"
   id="charts"
   ALIGN="">
<PARAM NAME=movie VALUE="charts.swf?library_path=charts_library&xml_source=sample.xml">
<PARAM NAME=quality VALUE=high>
<PARAM NAME=bgcolor VALUE=#666666>

<EMBED src="charts.swf?library_path=charts_library&xml_source=sample.xml"
quality=high
bgcolor=#666666
WIDTH="400"
HEIGHT="250"
NAME="charts"
ALIGN=""
swLiveConnect="true"
TYPE="application/x-shockwave-flash"
PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer">
</EMBED>
</OBJECT>

Your XML file has all the data and options to drive the chart. You can point to a ColdFusion file as well to have dynamic data. The set of chart types is pretty impressive, as is all the options you can use, including funky animations and layout. See the gallery for examples.

Probably the coolest option they have though is their live update option. This lets you point to XML data and automatically refresh every N seconds. Here is an example that points to a CFM on my server. Region C will change every 2 seconds.

Comments

Just a quick comment to my own post. I noticed in Firefox 3, OSX, the chart example above isn't centered right. It worked fine on my local server, and worked fine in the blog admin, so I'm thinking some CSS may be messing with it. The same blog entry works fine in Safari. So blame FF3/my css, not the chart engine.
# Posted By Raymond Camden | 1/4/08 7:59 AM
*All* regions are updating every 2 seconds...not just 'C'
# Posted By todd sharp | 1/4/08 8:10 AM
Nope I lied and shall be banned from all comments on this blog for the rest of the day.
# Posted By todd sharp | 1/4/08 8:11 AM
I found a great set of free Flash charts that I used for a recent app I built. They're XML based and SUPER easy to use:

http://www.fusioncharts.com/free/
# Posted By Andy Matthews | 1/4/08 8:41 AM
Wow, those are impressive! Wonder why they're free though...seems like something they could easily charge for.
# Posted By Gareth | 1/4/08 9:09 AM
I discovered an open source alternative for flash charts. In my opinion they do look pretty good, plus I'm sure once the developer manages to get a copy of Flash 9, they'll get a whole lot better.

http://teethgrinder.co.uk/open-flash-chart/
# Posted By David Boyer | 1/4/08 9:11 AM
@Gareth: Check the license for XML/SWF. The free version blocks linking, so you can't tie a bar to a url for example. (That's based on my super quick reading.) The 45 dollar version doesn't have this limit.
# Posted By Raymond Camden | 1/4/08 9:14 AM
If you're already implementing jQuery, take a look a Flot: http://code.google.com/p/flot/
# Posted By Eric Hynds | 1/4/08 10:05 AM
If you want to see some *AMAZING* charting checkout GlobFX:

http://www.globfx.com/products/swfchart/samples.ph...

What's awesome about it is they use a CSS concept for the styling, so the design and logic are completely separate. Want to change your chart from a stacked area to a column series? No problem, just update your chart style sheet.

And the Stylesheet granularity is crazy. The level of minute detail that you can control. But here's the best part - creating these style sheets is done in a style sheet tool that non developers can use, so you can let your marketing or project management team set up the style that they want and then they just hand over the style sheet to you and you're done. The tool let's you punch in some mock data so that you can see what the style is going to look like without having to plug it into a back end.

They have Coldfusion samples available.

Check out the gallery:
http://www.globfx.com/products/swfchart/samples.ph...
# Posted By Darth Sidious | 1/4/08 10:55 AM
Those are freaking amazing!
# Posted By Andy Matthews | 1/4/08 11:00 AM
I did a project using the XML/SWF charts last year with some nice success (I'd link but the charts are all behind a login). It was easy to use (I was using PHP for that project but it would have been even easier with CF) and the client loved the look of them. Anyhow, it was certainly worth the $45 dollars since it would have taken way more money to build it myself.
# Posted By Kevin | 1/4/08 1:35 PM
We use Kavachart for all our visualization.
They have some good documentation on integrating with CF, and my experience with their support has been great.

http://www.ve.com/kavachart/gallery.html
# Posted By Gary | 1/7/08 5:18 PM
hey guys, I have found a set of open source chart controller called http://visifire.com powered by silverlight just for free
# Posted By vin45 | 6/16/08 6:08 AM