Home > Back-end >  Tchart controls how to remove the initial curve in Delphi?
Tchart controls how to remove the initial curve in Delphi?

Time:11-09

My demand is to draw a graph, real time read from single-chip computer real-time data source, the graph initialization from the coordinate zero dot, after full display area, a new point to launch to the old point (i.e., the point out to the left of the point on the right) to keep the real-time, according to new data to the old data points with the mouse can be back to see,

The problems at present:
Question 1: the Tchart Delphi controls how to remove the initial curve (the initial curve is random, is different each time it is open or refresh) in control is set to cancel it? As shown in figure:

Note: data of the normal curve is my own MCU data, the initial curve is given by the tchart default now you want to cancel when I do not know how to cancel it,

Question 2: if successful cancel after initial curve "question 1", I'm a normal data curve coordinates from 0 to get? If not how do I set starting from 0 0 start?

Question 3: because be Delphi beginners, Tchart dot curve data code from the Internet to find, to achieve "old data point with the mouse can back view", the function still have some problems, may be used in the code the Delete (0); Every time the refresh data deleted the front points, cause only shows that the curve of the box, drag back to empty,
Attach some code below, please correct me bosses about
Procedure TForm1. GraphTimer (Sender: TObject);
Var tmpX: Double;
Inputvalue: Double;
The begin
Inputvalue:=IdataToIdouble (13);//load the data
With Series1 do
The begin
TmpX:=XValues [1] - XValues [0].
Delete (0);
AddXY (XValues. Last + tmpX inputvalue, ' ', clTeeColor);
end;
end;

The above 3 questions please be familiar with the Tchart bosses solve, thank you thank you

CodePudding user response:

Fyr,
Question 1, 2: should run before using Series1. The clear; Should be can solve.
Question 3: double-click the chart, called the Settings page, select chart & gt; The General & gt; Mouse/zoom setting parameters, should not delete data.

CodePudding user response:

How do I remove the white square?

CodePudding user response:

Not removed, you can only set up a few rungs

CodePudding user response:

https://download.csdn.net/download/yangxiaojia27/9710965 can help to you
  • Related