Jeff7102:
Hi,
I am not a coder but have been trying to learn over time, so please bear with me (and be gentle, lol). I have an EA that trades off the highest high and lowest low over a period of Monday H1 bars. I want to test this EA on open prices only (not every tick), but am having trouble modifying the code to work on open prices. Here is the code that finds the highest high and lowest low, which I follow. This has to be fairly common, but is there a similar function that finds the highest open and lowest open? I looked around and am guessing not, that I need to make an array first? Any help is appreciated. Thanks!
Jeff
Try this :
MonHigh=iOpen(strSymbol,PERIOD_H1,iHighest(strSymbol,PERIOD_H1,MODE_OPEN,EndOfZoneDetermingHour,0)); if(MonHigh>HighMondayZone)HighMondayZone=MonHigh; MonLow=iOpen(strSymbol,PERIOD_H1,iLowest(strSymbol,PERIOD_H1,MODE_OPEN,EndOfZoneDetermingHour,0)); if(MonLow<LowMondayZone)LowMondayZone=MonLow;
Thank you! I will try that out. Such a simple fix.

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
Hi,
I am not a coder but have been trying to learn over time, so please bear with me (and be gentle, lol). I have an EA that trades off the highest high and lowest low over a period of Monday H1 bars. I want to test this EA on open prices only (not every tick), but am having trouble modifying the code to work on open prices. Here is the code that finds the highest high and lowest low, which I follow. This has to be fairly common, but is there a similar function that finds the highest open and lowest open? I looked around and am guessing not, that I need to make an array first? Any help is appreciated. Thanks!
Jeff