Работа завершена
Техническое задание
Hello Mates! I need an open source file of a very simple algorithm written in MQL5 for use on Metatrader5.
I have quite unusual requirements for it, which I unfortunately was not able to satisfy by independently studying the topic and searching for analogues.
The algorithm consists of the following actions: opens a market position in a preset direction with a preset position size, as well as preset Take Profit and preset Stop Loss.
No any indicators are used as a trigger - only the bot start (or maybe time preset). When closing a position by Take Profit, it repeats the first action.
When closing by Stop loss - executes the second command with same list of customizable parameters. Thus, six consecutive commands with customizable parameters each: Take Profit, Stop Loss, position size and direction.
This trading commands should follow one-by-one and only one trade can occur at a time. When Take Profit is executed on any of the trades in the queue, the bot starts from the beginning.
When a trade is closed using Stop Loss, it moves on to the next task except the sixth. The latter task number six resets the cycle to the first, regardless of the outcome of the transaction.
Robot should stop working on reaching preset of total Profit or total Loss.
I understand that probably the biggest complexity and part of the work is that each trade out of six has its own settings and I'm going to change them often, so I need open source code (minimal comments included to see where this parameters <3) so that I can change these parameters myself.
Also please take a look on attached picture, it might help in explanation.