Jump to content
Software FX Community

x axis formatted as date

User (Legacy)

Recommended Posts

on the x axis i am showing a series of dates.  i want to ensure that the 

first date label is the min date and the last label is the max date.

how do i better control the labelling of the axis?

for example, if my date range is 1/1/2006 to 3/31/2006, i want 1/1 and 3/31

to appear on the chart.

any feedback or references are appreciated.

thanks, rick..

Link to comment
Share on other sites

  • 7 months later...


Did you ever figure out a fix for your problem?  I have a similar issue with dates on the x-axis.

In my case, I am trying to explicitly specify a Min and Max for the x-axis so that I might pass data to the chart that is outside of this Min and Max date range, but the chart will "clip" the graph region's visible area to the Min-Max time span.

Any insight that you have gained on using dates on the x-axis might help me.

 Thanks in advance for any reply.

LDavies  "Mick"

Link to comment
Share on other sites

The important thing here is whether or not your chart is an X/Y chart. This depends on two things:

1) You are passing X-Values to the chart

2) The gallery you are using supports X/Y Charts. These galleries are: Lines, Scatter, Area, Bubble and Step.

If your chart support X-Values, you can set the Min and Max to any number and the data will be clipped accordingly, otherwise, you need to use AxisX.SetScrollView to set the view to only those points you want. Because in this case the X-Axis is categorical, SetScrollView expects the index of the points to be displayed not the corresponding Date values. For example:



will display the from the second point to the 10th regardless of their value.


Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Create New...