![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Yes I am sure I am getting the error with the code. I will try to reduce some of the craziness. I thought ChartIndicatorAdd was necessary to get the MA's on the chart. I can remove these
It's weird to have this error with this code. I noticed there is some regularity in the error in your log, around 45 to 50 seconds between each one, so it's not on every tick. Do you have other indicators running on the same chart or symbol ? Try to use it alone.
If you want to have the MA's on the chart, yes use ChartIndicatorAdd, but not on each tick, and what I meant is it's not necessary to use CopyBuffer().
It's weird to have this error with this code. I noticed there is some regularity in the error in your log, around 45 to 50 seconds between each one, so it's not on every tick. Do you have other indicators running on the same chart or symbol ? Try to use it alone.
If you want to have the MA's on the chart, yes use ChartIndicatorAdd, but not on each tick, and what I meant is it's not necessary to use CopyBuffer().
Thank You Alain. Thanks for your feedback. I have tried to read up on CopyBuffer(), I thought it was necessary - I have read the function - but I can't see where it indicates its advantage - what is the advantage of using CopyBuffer? I thought I needed it to copy the data into the variables so that they may be used for my analysis. is that not the case?
Thank You Alain. Thanks for your feedback. I have tried to read up on CopyBuffer(), I thought it was necessary - I have read the function - but I can't see where it indicates its advantage - what is the advantage of using CopyBuffer? I thought I needed it to copy the data into the variables so that they may be used for my analysis. is that not the case?