Prix: Good afternoon. If anyone knows where you can download a ZIGZAG indicator that marks the point at which a new beam appears (e.g. in a different colour). If there is one at all...
Help me deal with arrays passed to iMAOnArray function.
For some reason, this function works only with buffer array (in VMA example)
and won't work with "regular" (SMA, for example).
Below is an outline of how I do it in my programs. What's wrong?
double MA1[],MA2[],VMA[],SMA[];
int init()
{
SetIndexBuffer(0,MA1);
SetIndexBuffer(1,MA2);
SetIndexBuffer(2,VMA);
SetIndexEmptyValue(0,0.0);
SetIndexEmptyValue(1,0.0);
SetIndexEmptyValue(2,0.0);
ArrayResize(SMA,1);
ArrayInitialize(SMA,0);
return(0);
}
int start()
{
SMA[i]=...........;
VMA[i]=...........;
MA1[i]=iMAOnArray(SMA,0,8,0,0,0); //----этот вариант НЕ работает
MA2[i]=iMAOnArray(VMA,0,8,0,0,0); //----этот вариант всегда работает return(0);
}
I've already written to you about this, but you chose to ignore it:
When declaring an array, which is not an indicator buffer, you MUST specify its size, preferably larger, so that the interpreter allocates memory space.
If I understand correctly, the point shows not when the new ray appears, but the maximum or minimum of the candle on which it appeared... But not bad either... thanks...
Help me deal with arrays passed to iMAOnArray function.
For some reason, this function works only with buffer array (in VMA example)
and won't work with "regular" (SMA, for example).
Below is an outline of how I do it in my programs. What's wrong?
The sequence of preparation of SMA[] and VMA[] arrays is not clear from this code fragment, assuming that you declared the size of a "non-buffer" array.
These arrays must be filled with data first, and then arrays MA1[] and MA2[] must be created using iMAOnArray().
I've already written to you about this, but you chose to ignore it:
When declaring an array, which is not an indicator buffer, you MUST specify its size, preferably larger, so that the interpreter allocates memory space.
I've given it a size from 1 to Bars. Both during declaration and ArrayResize, nothing changed;(
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
Good afternoon. If anyone knows where you can download a ZIGZAG indicator that marks the point at which a new beam appears (e.g. in a different colour). If there is one at all...
Look for DT_ZZ_Nen
Look for DT_ZZ_Nen
Thanks, I'll try it now.
Below is an outline of how I do it in my programs. What's wrong?
I've already written to you about this, but you chose to ignore it:
When declaring an array, which is not an indicator buffer, you MUST specify its size, preferably larger, so that the interpreter allocates memory space.
Look for DT_ZZ_Nen
If I understand correctly, the point shows not when the new ray appears, but the maximum or minimum of the candle on which it appeared... But not bad either... thanks...
Below is an outline of how I do it in my programs. What's wrong?
The sequence of preparation of SMA[] and VMA[] arrays is not clear from this code fragment, assuming that you declared the size of a "non-buffer" array.
These arrays must be filled with data first, and then arrays MA1[] and MA2[] must be created using iMAOnArray().
I've already written to you about this, but you chose to ignore it:
When declaring an array, which is not an indicator buffer, you MUST specify its size, preferably larger, so that the interpreter allocates memory space.
I usually do this with a non-buffered one.