TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
-
moelski
- Advanced
- Posts: 212
- Joined: Mon Apr 23, 2007 12:00 am
- Location: Germany
-
Contact:
Post
by moelski » Mon Apr 14, 2008 5:48 am
Hi !
I have a chart with one bar graph (like in the picture). I only show one value in this chart but this value will be updated every second.
Code: Select all
Val := TrackBar1.Position / 10 - 20;
Chart1[0].BeginUpdate;
Chart1[0].Clear;
Chart1[0].AddXY(Val, 0);
Chart1[0].EndUpdate;
Chart1.Title.Caption := FloatToStr(Val);
Is it possible to have an indicator for the minimum and maximum value that was shown within the chart?
Example:
I have an actual value of 50. The smallest value that was shown within the chart was 25 and the biggest value was 65.
Is this possible? And is it possible to access the Min / Max values for further usage in the code (something like this ... Chart[0].MinMaxIndicator.Min)?
-
Yeray
- Site Admin
- Posts: 9612
- Joined: Tue Dec 05, 2006 12:00 am
- Location: Girona, Catalonia
-
Contact:
Post
by Yeray » Mon Apr 14, 2008 9:49 am
Hi Dominik,
I think you could use a line series to do this (with Pointer.Visible activated) with two points, for example. You could use two variables to store the global minimum and maximum, and modify XValue[0] or XValue[1] from you line series when those variables are updated.