How to constrain datetime zooming

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
ChrisR
Newbie
Newbie
Posts: 4
Joined: Fri Jan 12, 2007 12:00 am
Location: Auckland, NZ
Contact:

How to constrain datetime zooming

Post by ChrisR » Tue Jan 16, 2007 8:32 pm

I have a graph of daily harvest totals. So I have set the x-values to datetime and the display mask to "dd-mmm".

However, when the user zooms in, I end up with several ticks and labels on the x-axis for the same day.

As the data can be sparse, (i.e. daily totals can often be zero near the beginning and end of the season), these spurious ticks and labels could confuse the user.

Yeray
Site Admin
Site Admin
Posts: 9612
Joined: Tue Dec 05, 2006 12:00 am
Location: Girona, Catalonia
Contact:

Post by Yeray » Wed Jan 17, 2007 9:42 am

Hi ChrisR,
I think you need to change your bottom axis increment like this:

Code: Select all

Chart1.Axes.Bottom.Increment := DateTimeStep[dtOneDay];
Best Regards,
ImageYeray Alonso
Development & Support
Steema Software
Av. Montilivi 33, 17003 Girona, Catalonia (SP)
Image Image Image Image Image Image Please read our Bug Fixing Policy

Post Reply