Hi everybody and a good day. I coded 6 indicators that trace automatic channels on different timeframes, they work flawlessly alone but they stop working when applied together to the chart.
Every indicator use a handle to get the timeframe IMA data and I declared them in OnInit as you said.
First indicator handle:
second indicator handle:
Third indicator handle:
Fourth indicator handle:
Fifth indicator handle:
Sixth indicator handle:
Also, every indicator use different variable names for the icons, the lines and internal calculations.
During debug I noticed the indicators stop calculate the iMAs when working together. What could it be the problem?
Are you using objects on chart? Sometimes object names interfere with each other.
Yes, there are many objects, buy I accurately named them differently. But even if the object name interfered with each other I cannot explain why the iMA calculations stop.
Is there some kind of buffer or other internal metatrader function that get overwhelmed?
Yes, there are many objects, buy I accurately named them differently. But even if the object name interfered with each other I cannot explain why the iMA calculations stop.
Is there some kind of buffer or other internal metatrader function that get overwhelmed?
I don't think the code would clarify anything, there are only internal calculations and it would lead out of topic.
I'm only wondering if in the metatrader there is some kind of buffer or other internal function that get overwhelmed by using too much the iMA function or other function. Thanks
During debug I noticed the indicators stop calculate the iMAs when working together. What could it be the problem?
What does this "stop calculate" mean?
Also, every indicator use different variable names for the icons, the lines and internal calculations.
During debug I noticed the indicators stop calculate the iMAs when working together. What could it be the problem?
-
Variable names are irrelevant. Only Global Variables of the Terminal and object names can be seen outside a program.
-
How To Ask Questions The Smart Way. (2004)
Don't rush to claim that you have found a bug.
Questions Not To Ask
My program doesn't work. I think system facility X is broken.It is almost always your code.
-
On MT4: Unless the current chart is that specific symbol(s)/TF(s) referenced, you must handle 4066/4073 errors before accessing candle/indicator values.
Download history in MQL4 EA - MQL4 programming forum - Page 3 #26.4 (2019)On MT5: Unless the current chart is that specific pair/TF, you must synchronize the terminal Data from the Server before accessing candle/indicator values.
Error 4806 while using CopyBuffer() - Expert Advisors and Automated Trading - MQL5 programming forum #10 (2020)
Is it mystical?! It is! - Withdraw - Technical Indicators - MQL5 programming forum (2019)
Timeseries and Indicators Access / Data Access - Reference on algorithmic/automated trading language for MetaTrader 5
Synchronize Server Data with Terminal Data - Symbols - General - MQL5 programming forum #2 (2018)
SymbolInfoInteger doesn't work - Symbols - General - MQL5 programming forum (2019)
Hi everybody and a good day. I coded 6 indicators that trace automatic channels on different timeframes, they work flawlessly alone but they stop working when applied together to the chart.
Every indicator use a handle to get the timeframe IMA data and I declared them in OnInit as you said.
First indicator handle:
second indicator handle:
Third indicator handle:
Fourth indicator handle:
Fifth indicator handle:
Sixth indicator handle:
Also, every indicator use different variable names for the icons, the lines and internal calculations.
During debug I noticed the indicators stop calculate the iMAs when working together. What could it be the problem?
Wait, do you call them together or do you create the OnInit function for each one?
void OnInit() { handleM1=iMA(NULL,PERIOD_M1,1,0,MODE_SMA,PRICE_MEDIAN); handleM5=iMA(NULL,PERIOD_M5,1,0,MODE_SMA,PRICE_MEDIAN); handleM15=iMA(NULL,PERIOD_M15,1,0,MODE_SMA,PRICE_MEDIAN); handleH1=iMA(NULL,PERIOD_M1,60,0,MODE_SMA,PRICE_MEDIAN); handleH4=iMA(NULL,PERIOD_M1,240,0,MODE_SMA,PRICE_MEDIAN); handleD1=iMA(NULL,PERIOD_M1,1440,0,MODE_SMA,PRICE_MEDIAN); }
I don't think the code would clarify anything, there are only internal calculations and it would lead out of topic.
I'm only wondering if in the metatrader there is some kind of buffer or other internal function that get overwhelmed by using too much the iMA function or other function. Thanks
No. The issue comes from your code.

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hi everybody and a good day. I coded 6 indicators that trace automatic channels on different timeframes, they work flawlessly alone but they stop working when applied together to the chart.
Every indicator use a handle to get the timeframe IMA data and I declared them in OnInit as you said.
First indicator handle:
second indicator handle:
Third indicator handle:
Fourth indicator handle:
Fifth indicator handle:
Sixth indicator handle:
Also, every indicator use different variable names for the icons, the lines and internal calculations.
During debug I noticed the indicators stop calculate the iMAs when working together. What could it be the problem?