What confuses you in this code?
//--- create m_handle=iMA(symbol,period,ma_period,ma_shift,ma_method,applied); //--- check result if(m_handle==INVALID_HANDLE) return(false);
Everything is correct: the correctness of the created handle is checked, and if the handle was not created, then there is an error.
The attached file, ExpertMAPSARSizeOptimized, came standard with MetaEditor.
It is in the Expert/Advisors folder. While debugging I noticed there were errors in the Trend.mqh file, lines 812 to 815.
Has anyone had a similar experience? I also debugged another Expert Advisor generated from the Wizard and placed the breakpoint in the OnTick event handler.
It did not pause at the breakpoint. I noticed it paused at the breakpoint when it is placed in OnInit.
I soon realize that in the case of the breakpoint in OnTick, the program had terminated before it got to the breakpoint.
In tracing the program, the exit point was inside one of the derived class which is in the Standard library.
Any ideas, I am studying these libraries and am reluctant to make changes.
There is no problem with this code.
Tested with build 2981 (production release) and 3036 (last beta).
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
The attached file, ExpertMAPSARSizeOptimized, came standard with MetaEditor.
It is in the Expert/Advisors folder. While debugging I noticed there were errors in the Trend.mqh file, lines 812 to 815.
Has anyone had a similar experience? I also debugged another Expert Advisor generated from the Wizard and placed the breakpoint in the OnTick event handler.
It did not pause at the breakpoint. I noticed it paused at the breakpoint when it is placed in OnInit.
I soon realize that in the case of the breakpoint in OnTick, the program had terminated before it got to the breakpoint.
In tracing the program, the exit point was inside one of the derived class which is in the Standard library.
Any ideas, I am studying these libraries and am reluctant to make changes.