Well I wrote a simple ea that does not work. Any ideas from anyone why it does not follow the rules.
The Rules: On a M5 Chart when the second line from the bottom of the N4 TF HAS Bar (M15 Line) Changes from blue to red go short & when it changes from red to blue to go long. This is not on the current bar of the chart but one bar back as to avoid the current bar from changing from blue to red then back to blue. As you can see in my examples its not following these rules at all, not even close and since im not a coder I have no clue why. Any assistance would be great!
chart.gif
chart2.gif
N4 TF HAS Bar Example EA.mq4