Only open new trade if last trade is closed x minutes before
-
Hello!
I have an EA like this:
Indicator XY = Y --> No trade --> Buy now
I would like to only open a trade if the last trade was closed 10 or more minutes ago.
How can i do this?
Thank you very much.
-
This is easy using a variable.
For instance, a variable called minutes
- on every minute, modify minutes to minutes + 1
- OnTrade -> position closed -> modify minutes to 0
- now you can check from the variable minutes how many minutes have passed since last close
-
Thank you.
Is there any other possibility, for example „check last trades“?
-
I will suggest this combination of blocks:

The first block loads the last closed trade. Then "check age" checks the close time of that trade. And then after "check age" you do whatever you want.