[flexcoders] DateTimeAxis labels

2010-07-14 Thread Richard Rodseth
My stakeholders almost always seem to want something for DateTimeAxis labels
that I can't give them out of the box.
Example: I have a weeks worth of data in 15-minute increments, and would
like the labels at 12AM and 12PM. Or if only one per day, at 12PM rather
than 12AM.

But if I set labelUnits to hours, I get one label per day at 12AM.

Anyone discovered any tricks?


Re: [flexcoders] DateTimeAxis labels

2010-07-14 Thread Brendan Meutzner
Have you looked at using a custom IAxisRenderer for the series in which you
limit the labels which are shown?  You would be able see the labels which
are to be displayed and show/hide them accordingly.  I believe that you'll
find the setter for gutters has the labels which are added automatically.


Brendan



On Wed, Jul 14, 2010 at 4:56 PM, Richard Rodseth rrods...@gmail.com wrote:



 My stakeholders almost always seem to want something for DateTimeAxis
 labels that I can't give them out of the box.
 Example: I have a weeks worth of data in 15-minute increments, and would
 like the labels at 12AM and 12PM. Or if only one per day, at 12PM rather
 than 12AM.

 But if I set labelUnits to hours, I get one label per day at 12AM.

 Anyone discovered any tricks?


  



Re: [flexcoders] DateTimeAxis labels

2010-07-14 Thread Richard Rodseth
Before embarking on potentially time-consuming or risky customization, we
usually have to weigh other priorities. But thanks, I'll keep that in mind,
and look into it when time permits.

On Wed, Jul 14, 2010 at 3:30 PM, Brendan Meutzner bmeutz...@gmail.comwrote:



 Have you looked at using a custom IAxisRenderer for the series in which you
 limit the labels which are shown?  You would be able see the labels which
 are to be displayed and show/hide them accordingly.  I believe that you'll
 find the setter for gutters has the labels which are added automatically.


 Brendan



 On Wed, Jul 14, 2010 at 4:56 PM, Richard Rodseth rrods...@gmail.comwrote:



 My stakeholders almost always seem to want something for DateTimeAxis
 labels that I can't give them out of the box.
 Example: I have a weeks worth of data in 15-minute increments, and would
 like the labels at 12AM and 12PM. Or if only one per day, at 12PM rather
 than 12AM.

 But if I set labelUnits to hours, I get one label per day at 12AM.

 Anyone discovered any tricks?



  



[flexcoders] dateTimeAxis labels missing from entire project?

2008-07-08 Thread blc187
Is it possible to have some type of global setting that removes label 
from the charting axes?
I've got a basic LineChart with a DateTimeAxis that is missing labels.
But when I copy the class to a new project and display the chart by 
itself, the labels are there and display fine.
I would like the labels to show, and I am not manipulating this class 
at all from anywhere else so I can't figure out how the labels might 
be getting shut off.

This is my class:

mx:Canvas xmlns:mx=http://www.adobe.com/2006/mxml; 
creationComplete=onInit() width=100% height=100%

mx:Script
![CDATA[
import mx.collections.ArrayCollection;
[Bindable] public var dataProvider:ArrayCollection;

//this is just to populate the data with a diagonal line
public function onInit():void {
dataProvider = new ArrayCollection();
var i:int = 10;
var date:Date;
while(i  0) {
date = new Date(2008, 8, 30-i, 10,11, 12);
dataProvider.addItem({date:date, yField:i});
i--;
}

}

]]
/mx:Script

mx:LineChart id=lineChart width=100% showDataTips=true 
dataProvider={dataProvider} height=100%
 
mx:horizontalAxis 
mx:DateTimeAxis id=dateTimeAxis labelUnits=days 
dataUnits=days /
/mx:horizontalAxis
mx:verticalAxis
mx:LinearAxis id=yAxis/
/mx:verticalAxis
mx:series
mx:LineSeries horizontalAxis={dateTimeAxis} 
yField=yField xField=date /
/mx:series

/mx:LineChart

/mx:Canvas