creating .canvas.lineto a high or low in a candle chart

TeeChart for ActiveX, COM and ASP
Post Reply
mdspeirs
Newbie
Newbie
Posts: 2
Joined: Wed Apr 07, 2004 4:00 am

creating .canvas.lineto a high or low in a candle chart

Post by mdspeirs » Fri Apr 30, 2004 3:03 pm

I'm using the following code to create a line to designated points on the a candle chart:

.Canvas.LineTo .Axis.Bottom.CalcXPosValue(.Series(0).XValues.Value(pt)), _
.Axis.Left.CalcYPosValue(.Series(0).YValues.Value(pt))


This works great for overlaying a line to the closing value, but I wants to send a line to a high or low value... How would I do that?

Pep
Site Admin
Site Admin
Posts: 3303
Joined: Fri Nov 14, 2003 5:00 am
Contact:

Post by Pep » Mon May 03, 2004 8:27 am

Hi,
This works great for overlaying a line to the closing value, but I wants to send a line to a high or low value... How would I do that?
for the low values you can do this :

Code: Select all

With TChart1    
    centery = .Axis.Left.CalcYPosValue(.Series(0).asCandle.LowValues.Value(3))
    centerx = .Axis.Bottom.CalcXPosValue(.Series(0).asCandle.DateValues.Value(3))
    .Canvas.LineTo centerx, centery
End With

Post Reply