Forum on trading, automated trading systems and testing trading strategies
EA opens Many Trades, How to Open 1 buy & 1 sell?
Vladimir Karputov, 2022.01.10 16:03
You have a huge mistake - you create an indicator handle at every tick.
REMEMBER: The MQL5 style implies that the indicator handle MUST be created ONLY ONCE and this must be done in OnInit !!!
hi new mql5 developer here
I have 2 errors can you help me?
'{' - function definition unexpected 4MA.mq5 462 1
exactly as the error says you have not provided any definition to the functions
the first looks like the code should belong in OnInit based upon the return code
the second is empty so delete it
you are probably in the mess because you have not laid your code out very well with bits and pieces everywhere
{ SetIndexBuffer(0,val,INDICATOR_DATA); SetIndexBuffer(1,valc,INDICATOR_COLOR_INDEX); iHull.init(inpPeriod,inpDivisor); IndicatorSetString(INDICATOR_SHORTNAME,"Hull ("+(string)inpPeriod+")"); return (INIT_SUCCEEDED); } { }
- 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 new mql5 developer here
I have 2 errors can you help me?
'{' - function definition unexpected 4MA.mq5 462 1