Help to reset variable once a day
-
I was working on my EA for Indices, i have everything run smoothly and had great results in the backtest.
I run the EA on both DEMO and REAL account at a time. I notice the two of them aren't opening trade exactly at the same time.
.
.
Sometimes the DEMO open trade but not on REAl and vice versa,
.
I notice that i use Once Per Day block to toggle a variable that controls the EA to only take one trade per day. So i think this was the culprit for the problem.
.
What i want to do since the Indices are open in a different time (example HangSengIndex open at 02 AM GMT and US30 open at 11 PM GMT), i want the Once Per Day block pass at the first candle of the day, so i was ready to execute signal from the indicator later on the day.
.
I tried to track this first candle of the day but don't get any result, is there any simpler solution for this? Thanks -
@everjn17 use the "once per bar" block and set that timeframe to D1
-
@everjn17 did you get the solution?