My custom indicator works as desired sometimes, but other times it doesn't work at all. When it fails, it is because the CopyBuffer() function fails to access requested rates. (See below). I've looked through the docs, and I don't think there is any coding I can do to make the indicator work reliably. So, I feel it must be a bug in metatrader 5. Should I report to service desk?
Your code assumes that the bar secondSymbol is already available. But rates_total may be different for that symbol. You need to include a check and anyway should avoid requesting the complete data of the ma on each call of OnCalculate which happens every tick.
My custom indicator works as desired sometimes, but other times it doesn't work at all. When it fails, it is because the CopyBuffer() function fails to access requested rates. (See below). I've looked through the docs, and I don't think there is any coding I can do to make the indicator work reliably. So, I feel it must be a bug in metatrader 5. Should I report to service desk?
Hi, you have to understand how multi-currency indicator works, and fix your code, as ugo58 suggest you.
It's not a bug in MT5. Feel free to ask more help.
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
My custom indicator works as desired sometimes, but other times it doesn't work at all. When it fails, it is because the CopyBuffer() function fails to access requested rates. (See below). I've looked through the docs, and I don't think there is any coding I can do to make the indicator work reliably. So, I feel it must be a bug in metatrader 5. Should I report to service desk?