Ivo,
I have an expert which does essentially this. To be able to query the trendline though, I've had to ensure each different trendline has a specific label.
price_top=NormalizeDouble(ObjectGetValueByShift("TrendlineTop", 1),MarketInfo(Symbol(),MODE_DIGITS))
The trendline in this case has the name "TrendlineTop"
Hope this helps you out - certainly works for me.
Cheers
Martin
I have an expert which does essentially this. To be able to query the trendline though, I've had to ensure each different trendline has a specific label.
price_top=NormalizeDouble(ObjectGetValueByShift("TrendlineTop", 1),MarketInfo(Symbol(),MODE_DIGITS))
The trendline in this case has the name "TrendlineTop"
Hope this helps you out - certainly works for me.
Cheers
Martin
Forex Trader:
Ivo,
I have an expert which does essentially this. To be able to query the trendline though, I've had to ensure each different trendline has a specific label.
price_top=NormalizeDouble(ObjectGetValueByShift("TrendlineTop", 1),MarketInfo(Symbol(),MODE_DIGITS))
The trendline in this case has the name "TrendlineTop"
Hope this helps you out - certainly works for me.
Cheers
Martin
Ivo,
I have an expert which does essentially this. To be able to query the trendline though, I've had to ensure each different trendline has a specific label.
price_top=NormalizeDouble(ObjectGetValueByShift("TrendlineTop", 1),MarketInfo(Symbol(),MODE_DIGITS))
The trendline in this case has the name "TrendlineTop"
Hope this helps you out - certainly works for me.
Cheers
Martin
Thank you, but can you share the rest of the code as well ? Please, thank you

You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Is it possible to create an alert to jump out when a price cross a previously drawn trend line?
What I mean is: I have a pattern and appropriate trendline already existing on the chart. I'd like to be alerted when this trendline is broken. Is it possible? How or any hints about?
If I get subsequent high/lows to draw a line it won't be streight, but rather zig-zag. I want 1st to drow the streight line and then ti lock for a break. I hope I've explained clear the idea . . .
Thank you
Ivo