|
Here's how far I got with it ... it's rather embarrassing because I don't know how to program MQL. I must have had 50 or so other indicators open and hacked about the code until I managed at least something but it's not working as well as I imagine it should.
The idea is to place Price Trender on the chart (instead of in a separate window) and then when:-
- wait for the bar to close;
- if the blue price trendline crosses the gold trendline, draw a dot;
- if the blue price trendline crosses up from below the gold trendline then the dot should be green and drawn underneath the bar;
- if the price trendline crosses down from above the gold trendline then the dot should be red and drawn above the bar.
Unfortunately, the code I've added has some unwanted side effects, such as drawing both green and red dots on the bar when price and trend line cross. I've tried putting some kind of logic in the program but this hasn't cured it.
Can someone skilled please look at the code and help me with this?
|