I need a modification for an Expert Advisor. I want to use the EA in MT4. Attached is a sample file EA.mq4
The following function should be added:
- Maximum number of orders
- EA closing when the maximum number of orders has been executed
I do not want to discuss the sense of these modifications. I am aware of the risks that can arise when trading.
The maximum number of orders should be adjustable in the source code.
How the modified EA should work, I imagined as follows:
When the Expert Advisor has executed a certain number of the orders, then it should be terminated. It does not matter if there is still an order open. The order will use a stop loss and a take profit. It is important that the EA is terminated after the number of executed orders.
I would like to transfer the source code later to another EA and test it on a demo account.