Terminate other EA for awhile and restart it after certain time
-
checked articles here and didnt find a clue about it
it has to work at first with terminal variables but after how to make the connection .. didnt get itwhat i need to do .. to run two EAs at same MT4 .. i need to add a function at one of them to freeze other EA for certain time and unfreeze it afterthat
every chart has a unique ID .. and it may help to identify the chart where we could freeze it temporary
is it possible ?
-
@saeed-2 Not completely sure I get it. Do you mean one EA on one MT4 should close temporarily a different EA on a different MT4?
-
@l-andorrà Same MT4 has two running EA with different magic number .. one of these EA has the function to freeze the other EA at certain condition and undo freezing at certain condition
-
@saeed-2 In that case, yes, you will need terminal variables to do that. I'm afraid I cannot help you there, I'm not a programer.

-
@l-andorrà thanks for bypass and replying
i have an issue with delaying activating a delay orderwhen condition meet .. i need EA to open pending order after 30 mins exactly .. how that could be function ?
thanks
-
unfortunttely you wouldnt be able to backtest it for accuracy, but you can use a timer to specific blocks on and off. perhaps that would fix your issue?
-
@saeed-2 You can create a separated structure counting 1M bars after the condition. However, that will never be as exact as jsauter suggests.
-
@jsauter86 yeah it works thanks .. swapping between on chart and on timer works well with turn on off blocks
-
@l-andorrà separate structure counting ... how can we do that ?
-
@saeed-2 You will need at least two variables. One for engaginf the counting structure (you can use a boolean one when the new trade is open) and then a second int variable used to count 1M bars. You can do it this way, for example:

Obviously you will have to reinitiate both variables when the trade is closed.
-
@l-andorrà smart one !
thanks for assistance ,, appreciated -
it will be like this ? on tick to generate the counting and on trade to reset the variable value to zero
-
- Update >> to switch off blocks again
-
@saeed-2 If that is the whole project, yes that woud do it.
-
@l-andorrà custom indicator is updating in an interval of 1 hour .. so i need to timer EA to open the trade after some mins
thanks for your help
-
@saeed-2 You're welcome.

