IncEnvelopesOnArray - MetaTrader 5 Library - MT4/MT5 Resources

CEnvelopesOnArray class is used to calculate envelopes on the indicator buffer.
This initialize() function calls the OnInit() method with the following parameters:
This solve() function calls the OnCalculate() method with the following parameters:
Additional methods:
Test_EnvelopesOnArray.mq5 is an indicator that demonstrates how to use the CEnvelopesOnArray class. The IncEnvelopesOnArray file must be located in the MQL5\Include\IncOnArray directory of the terminal data folder (the IncOnArray folder must be created). CMAOnArray class IncMAOnArray files are required for this class to work.
The envelope technical indicator consists of two moving averages , one of which moves upward and the other which moves downward. The choice of the optimal relative amount of margin offset is determined by market volatility: the higher the latter, the stronger the shift.

Attachment download
📎incenvelopesonarray.mqh (2.8 KB)
📎 incmaonarray.mqh (5.28 KB)
📎 test_envelopesonarray.mq5 (3.12 KB)
Source: MQL5 #822
IncEnvelopesOnArray - Important points before using the MetaTrader 5 library
This page has been supplemented with structured instructions, focusing on the purpose of EA source code, MQL4/MQL5 platform compatibility, testing process and risk control. Before downloading or deploying, it is recommended to first determine whether it is consistent with your own variety, cycle and account environment.
Suitable for who to use
- Users who want to quickly screen EA source code and are willing to do simulation disk verification first.
- People who need to compare MT4/MT5 EAs, indicators, scripts or source code projects.
- Traders who wish to record backtests, parameters and risk boundaries before placing a trade.
Testing and risk control suggestions
- First verify the default parameters in the strategy tester or demo account, and then adjust the symbol, period, spread and trading period one by one.
- Scalping, grid, martin, and high-frequency strategies should focus on observing maximum drawdowns, consecutive losses, slippage, and trading frequency.
- It is not recommended to run any document directly on the real disk. At least observe the simulated disk performance for 2-4 weeks first.
FAQ
Can MT4 and MT5 be used interchangeably?
Usually cannot be used directly. EX4/MQ4 corresponds to MT4, EX5/MQ5 corresponds to MT5, and the source code needs to be compiled in the corresponding MetaEditor.
Is this resource guaranteed to be profitable?
cannot. EAs, indicators and scripts can only be used as trading tools, and the results depend on parameters, market environment, spreads, slippage and risk control.
What else can I continue to watch?
Forex EA download , foreign exchange indicator download , EA evaluation , MQL5 CodeBase .
English Search Notes
This page is also optimized for English search intent around IncEnvelopesOnArray - MetaTrader 5 library . Related search terms include: MQL4 source code, MQL5 source code. Test any Forex EA, Expert Advisor, MT4/MT5 indicator, script or MQL source code with historical data and a demo account before live trading.
💡 Featured Recommendations
✍️ Latest by the author
- •
- •
- •
- •
- •
- •
📌 Popular topics
- •
- •
- •
- •
- •
- •
- •
- •
🔗 You May Be Interested In
- •
- •
- •
- •
- •
- •