Forum > TAChart

How to draw a line as threshhold on chart?

(1/1)

senglit:
Hi all,

I got a chart with LineSeries, on which data can be shown properly. Now I want to add 2 lines as threshold. When the users look at the chart they can see easily data under the lower threshhold line is safe, data between two threshold lines means warnning, data hight then the higher threshhold line is dangerous.

For example, all of the data is between 20 and 120, I want to draw the threshhold lines at 53 and 68. How to do it?

Thanks!

h-elsner:
I use ConstantLines, vertical or horizontal. You can make it visible or not in code, can change position, color and so on. For me this is good and fulfills all needs.

br HE

wp:
Yes, add a TConstantLine. Set its "Linestyle" to lsHorizontal or lsVertical for a horizontal or vertical line. The coordinate is defined by the value of "Position".

senglit:
Thanks for h-elsner and wp. I got what I want. :D


--- Quote from: h-elsner on April 23, 2021, 09:03:53 am ---I use ConstantLines, vertical or horizontal. You can make it visible or not in code, can change position, color and so on. For me this is good and fulfills all needs.

br HE

--- End quote ---

Navigation

[0] Message Index

Go to full version