CLOSE TERMINAL
-
Hey,
If I have an MT5 bot that opens a trade on Monday and for my trade to exit the bot needs to monitor it going above a certain profit then it exits when emas cross. My bots are managed by group counters and everything works. My question is if i close the MT5 terminal with a trade open and restart the terminal will the bots still manage that position? or will it not realize it opened it
-
Depend on your EA
-
@Ren12 In general, as sktsec said, that depends on your current structure, but more than probably they will be lost for the bot unless you use this block:

But using it can changes the bot's performance.
-
@l-andorrà What about something like this
https://fxdreema.com/shared/h3lwPrwRc
How could i incorporate that pink block
its for MT5 -
I will add this, every red block in the picture is pointless or used incorrectly:

-
@jstap Would this solve my issue with managing trades opened before the terminal is restarted?
-
As this is what's placing the trade? it should not be able to place a trade until it's started, explain a little more about what you mean...
-
My logic is
once profit crosses $4500
the trade will close if price crosses one of the ichimoku cloud lines or if price closes below 2500 it will exit the trade
I know it works in back tests etc but im wondering if i retart my pc and then load back into mt5 will it still be able to manage the trade in this way ? will the ea know to do this as its still magic number operated -
No, but you can create a terminal (global) variable, and use this instead, these are stored on your computer, so closing doesn't affect the value.
-
How od i use a global variable ?
-
Something like what's in this link, create the name of the global variable so if you change settings it changes with them, then use in the place of other blocks.
In here https://fxdreema.com/shared/vJBopmrEd is an example -
@jstap I see ren12 use the pass block, what is the pass block use for vs not using it?
-
if you have a single block it will not work, so by placing a pass the block will work, generally I will put the pass block above, but any block connected to another will make it work
-
@jstap thank you
-
@jstap JUst asking. If I understand that correctly, the values of all those variables would be stored into those terminal variables even the platform is closed. Right? Does it mean they can only be reset via the bot itself? Are they automatically reset through other means?
-
F3 in your platform will open the variable panel, from here you can manually change the value, but normally it would take an EA to change, any EA on the platform will do it so you can use it to make an EA work on another EA.
-
Great! Thank you.

-
Thank you, and I forgot to say yes these values are stored so even if the terminal closes/crashes they are saved
-
@jstap Thanks!
