Get/retrieve Horizontal line Object name with a known price level
Get/retrieve Horizontal line Object name with a known price level
19 Nov 2022, 01:49
Hello Guys,
Can you please assist, I'm currently using the below code to find/get the price of the max/highest Horizontal line on chart:
Var lines = Chart.FindAllObjects<ChartHorizontalLine>();
foreach(var line in lines)
{
double Max_Line_Price = lines.max( x => x.Y);
}
I want to get the string Name of the same/specific line, how can i retrieve it?
String Max_Line_Name = ?
Replies
Willie_Dladla
23 Nov 2022, 21:19
RE:
PanagiotisChar said:
Hi there,
Try this
var lineName = lines.OrderByDescending(l => l.Y).First().Name;
Need help? Join us on Telegram
Need premium support? Trade with us
Thank you PanagiotisChar I appreciated it.
@Willie_Dladla
PanagiotisChar
21 Nov 2022, 08:48
Hi there,
Try this
Aieden Technologies
Need help? Join us on Telegram
Need premium support? Trade with us
@PanagiotisChar