This question came in via my forums, but I thought it would make a nice blog post. wolfee asks:
Is it possible to show a cfchart with bars but exclude the values (both on the verticle axis and on rollover? I'd like to give a visual indication of scores but not reveal the actual scores. Thankyou for any tips offered!
The answer is - of course - yes - since everything is possible with ColdFusion. (Ok, maybe not everything, but darn close!) As always, the answer is in the chart editor. I opened it up and simply disabled the Y-Axis. I then disabled Popup. That’s it. Done. Here is a simple example:
<?xml version="1.0" encoding="UTF-8"?>
<frame xDepth="12" yDepth="11"/>
<yAxis isVisible="false" scaleMin="0" />
<cfchart format=”flash” xaxistitle=”Fleet” yaxistitle=”numbers” style=”#style#”>
<cfchartseries type=”bar” serieslabel=”result”> <cfchartdata item=”Cylons” value=”75”> <cfchartdata item=”Colonials” value=”80”> </cfchartseries>
Note - I stripped the XML down to the bare minimum to get it working, but you get the idea. The visual result is:
Just pretend you can mouse over that and nothing shows up. Trust me - it works. ;) I’m not convinced this is 100% safe though. I bet you could get the SWF, decompile it, and see the numbers. Anyone want to try?