AddXY - Adding series during runtime
Posted: Tue Aug 29, 2006 5:24 pm
Hello,
I've just taken over some code from someone who left the company. I'm fairly new to using the TTeeChart components. I have a problem where a flat line continuously gets draw along 0 on the vertical axis. The code is fairly straightforward...
the x axis appears to be plotted correctly but the y axis is always flat. The *for loop* above is fine, i just wanted to reduce the code in this post. it can go through the loop any number of times, it depends on how many points there are to plot. I've traced it and every point is valid. Why does it always appear flat.
Thanks
I've just taken over some code from someone who left the company. I'm fairly new to using the TTeeChart components. I have a problem where a flat line continuously gets draw along 0 on the vertical axis. The code is fairly straightforward...
Code: Select all
acurve := TLineSeries.Create(Chart1);
*for loop*
acurve.AddXY(xvalue, yvalue);
*end loop*
with acurve do
begin
VertAxis := aLeftAxis;
HorizAxis := aBottomAxis;
ParentChart := Chart1;
LinePen.Width := 3;
end;
with acurve.Pointer do
begin
Visible := true;
HorizSize := 4;
VertSize := 4;
Style := psRectangle
end;
Thanks