Welcome Forex EA downloads & MT4/MT5 auto-trading resources — EAs, Gold EAs, quant tools and real-world automation.
Sign In Sign Up

Average by Signal - MetaTrader 4 Expert | MT4 EA Download - MetaTrader 4 Resources

author EAcpu | 5 reads | 0 comments |

This EA is created using the example of crossing the MA as an entry signal.
This EA was created for the purpose of learning MQL4 code.

Each open order will use a different magic number based on each pair. You can see how the EA manages different magicnumbers.

This ManageOrder() function will set the opening of new orders only based on the minimum distance between levels and averaging based on the presence or absence of a signal.

The setTPSLMarti() function can set TP for 1 position or multiple orders at the same TP price.

This sets the TrailingStop() function to set the trailing stop 1 position from the initial order.

For information and group sharing, please joint.me/codeMQL


Attachment download

📎 averagingbysignal.mq4 (14.61 KB)

Source: MQL5 #34466

Average by Signal - MetaTrader 4 Expert | MT4 EA Download - MetaTrader 4 Resource Usage and Screening Suggestions

This content can be used as a data entry for foreign exchange EA, indicators, trading systems or quantitative strategies. When reading, it is recommended to make a judgment based on the platform version, trading type, time period, risk control method and historical discussion background. Do not use it directly based on the title or a single point of view.

If the content involves MT4/MT5, ForexFactory, MQL source code, TradingView indicators or strategy discussions, you can give priority to the parameter logic, backtest environment, market stage, execution cost and failure conditions, and then decide whether to continue downloading, reviewing or secondary development.

Risk warning

For any EA, indicator or automatic trading strategy, it is recommended to first conduct historical backtesting, simulation account verification and small capital testing. Grid, Martin, high frequency, recovery and examination strategies especially require setting the account risk upper limit, single variety risk upper limit and manual deactivation conditions.

Verification code Refresh