Download Lock for MetaTrader 5

Lock

Lock

This professional-grade solution for MetaTrader 5 helps traders achieve greater efficiency in their daily workflow. This Expert Advisor serves as automated trading software. It is utilized to monitor financial markets and execute trades based on predefined algorithmic rules, enabling precise position management without the need for constant manual oversight.

MT5 expert Pack 📂

How to Setup and Use Lock

1. Installation: Open the "File" menu, select "Open Data Folder," navigate to MQL/Experts, paste your file, and restart the terminal.

2. Activation: Drag the EA from the Navigator onto a chart, ensure "Allow live trading" is checked in the Common tab, and verify the AutoTrading button is green.

3. Optimization: Right-click your chart, choose "Expert List," click "Properties" to adjust inputs, and save your preferred setup as a set file for future use.

4. Maintenance: Regularly check the "Experts" tab in the terminal window to monitor trade logs and potential execution errors.

Frequently Asked Questions

Q: Why is my EA not opening trades? A: Check the "AutoTrading" button, ensure "Allow live trading" is enabled, and verify your broker allows automated trading on your account type.

Q: Can I run multiple EAs on one chart? A: No, each chart can only host one active EA; however, you can open multiple charts for different currency pairs to run several EAs.

Q: What does the "smiley face" icon mean? A: A smiley face in the top-right corner of the chart indicates the EA is successfully running; a frowny face means it is disabled.

Description & Settings


Idea by
: .
MQL5 code by
: .
Suppose a trader enters the market with the Buy and Sell positions by an asset, where the currency is, say, at the level of 100. Then the prices moves to 200. Here, buying for 100 will be profitable, and selling for the same will be losing. We close our buy position, and the profit of 100 comes to our account. In this case, selling results in losing 100 units.
When using a grid, you should be sure of being able to make profit whatever direction is taken by the market. For this purpose, enter your Buy and Sell transactions again. Now, for the sake of convenience, let us assume that the price is moving to level 100 again.
The repeated selling will lead to +100, while the second buying will result in -100. According to the rules, you can close your sell position, and 100 more units will enter to your account. As a result, at this point, we have the total profit of 200.
Now, the first sell position that has remained active is moving from level 200 to level 100. It is in the breakeven range now.
Summing up the four transactions, we get the profits as follows: +100 for the first Buy; +100 for the second Sell; 0 for the first Sell, and -100 for the second Buy. The total profit has made +100. So we can delete all the orders and drink a glass of champagne. Prior to each subsequent double opening (simultaneous opening of Buy and Sell), we increase the lot size by the factor of
Lot exponential
.
There are many other market movements that make profitable these seemingly incomprehensible activities of simultaneous buying and selling.
However, in such trading, there is always a risk of "hanging" positions, i.e., positions that produce relatively high losses and have an opening price that is located very far from the current price. To overcome such "hanging" positions, we have introduced two parameters:
Excess of balance over Equity
(balance exceeding the Equity) and
Mimimum profit
.
In all cases, be careful, since two scenarios are possible: Optimistic
and pessimistic
Input parameters

Lots
- initial lot;

Take Profit
- Take Profit;

Lot exponential
- lot increase ratio;

Excess of balance over Equity
- balance exceeding the Equity;

Mimimum profit
- minimum profit;

magic number
- unique identifier for the EA.

You May Also Like

RobotFX does not own any of the code provided on this platform. All tools are freely available on the internet; we simply index and re-offer them for download. We are not responsible for any financial losses that may occur. Trading responsibilities rely solely on the traders downloading and using the displayed Expert Advisors, indicators, and scripts. These tools are provided for educational purposes only and may require modification or optimization to align with a trader's specific strategy or needs.
© ROBOTFX - Best MetaTrader Expert Advisors & Indicators