I'm using Teechart to create a simple line graph having two data series (both time series). In some cases these can span a period from 1880 - 2009. I find that on zooming a graph, or displaying a sub-set of the data, Dates before 1900 display with earliest in the RIGHT hand, while those after 1900 display with earliest in the LEFT.
The Activex is being used in a VB6 project.
The x-axis values being set are VB Date variables.
Can you advise me?
Many thanks
Mike Diggle (Draeger)
TeeChart : Dates as X axis values
Re: TeeChart : Dates as X axis values
Hi Mike,
I've tried to reproduce your problem with the following code. The only think that I've seen is that the labels earlier to 30/12/1899 aren't displayed. Is that what you mean?
If not, please, could you be so kind to send us a simple example project we can run as-is to reproduce the problem here?
I've tried to reproduce your problem with the following code. The only think that I've seen is that the labels earlier to 30/12/1899 aren't displayed. Is that what you mean?
Code: Select all
Private Sub Form_Load()
TChart1.Aspect.View3D = False
TChart1.AddSeries scLine
TChart1.AddSeries scLine
TChart1.Series(0).XValues.DateTime = True
TChart1.Series(1).XValues.DateTime = True
For i = 0 To 5
TChart1.Series(0).AddXY DateValue("1/0" & Trim(Str$(i + 1)) & "/1880"), Rnd * 100, "", clTeeColor
TChart1.Series(1).AddXY DateValue("1/0" & Trim(Str$(i + 1)) & "/1880"), Rnd * 100, "", clTeeColor
Next i
For i = 0 To 5
TChart1.Series(0).AddXY DateValue("1/0" & Trim(Str$(i + 1)) & "/2009"), Rnd * 100, "", clTeeColor
TChart1.Series(1).AddXY DateValue("1/0" & Trim(Str$(i + 1)) & "/2009"), Rnd * 100, "", clTeeColor
Next i
TChart1.Repaint
TChart1.Axis.Bottom.SetMinMax DateValue("1/01/1880"), DateValue("1/01/1900")
End Sub
Best Regards,
Yeray Alonso Development & Support Steema Software Av. Montilivi 33, 17003 Girona, Catalonia (SP) | |
Please read our Bug Fixing Policy |
-
- Newbie
- Posts: 4
- Joined: Thu Oct 18, 2007 12:00 am
Re: TeeChart : Dates as X axis values
Thanks for your help - we've just upgraded to the latest version of Tchart , and that seem to have fixed the problem.
Mike Diggle - Draeger
Mike Diggle - Draeger