alitavana:
Hi Experts,
I use iStochastic function to check Main and Signal values and do something with them.
but when i call the array, the error <array out of range> shown in the journal section.
the code is here:
I did this with many indicators like iADX, iMA, etc...
Only iStochastic Shows (array out of range)
any help will be appreciated
Interesting... no problem on my PC.
CopyBuffer(stoHandle,0,0,3,mainLin); CopyBuffer(stoHandle,1,0,3,sigLin);
To avoid the error Check your return codes for errors, and report them including GLE/LE. Don't look at it unless you have an error. Don't just silence the compiler, it is trying to help you.
What are Function return values ? How do I use them ? - MQL4 and MetaTrader 4 - MQL4 programming forum
Common Errors in MQL4 Programs and How to Avoid Them - MQL4 Articles
Only those functions that return a value (e.g. iClose, MarketInfo, etc.) must you call ResetLastError before in order to check after.- It takes time to compute, get the handle in OnInit.

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
Hi Experts,
I use iStochastic function to check Main and Signal values and do something with them.
but when i call the array, the error <array out of range> shown in the journal section.
the code is here:
I did this with many indicators like iADX, iMA, etc...
Only iStochastic Shows (array out of range)
any help will be appreciated