Hi,
I would like to build an EA using the Alligator indicator which consists of three moving averages. Therefore, I tried to copy the values of these moving averages into an array, as I've done before with the CCI indicator.
However, I get the error message: "Jaws" - parameter conversion not allowed.
So first I initialize the three arrays and the Alligator handle:
In the OnInit handle I create the indicator Alligator:
Then, within the OnTick handle I do the following to copy the indicator values to the three arrays:
Can maybe someone tell what I am doing wrong? Thanks!
Which line gives you the error ?
What is the code of your CopyBufferAsSeries function ?
Which line gives you the error ?
What is the code of your CopyBufferAsSeries function ?
The error appears for the in which I call the function CopyBufferAsSeries.
And this is the CopyBufferAsSeries function:
bool CopyBufferAsSeries( int handle, // handle int bufer, // buffer number int start, // start from int number, // number of elements to copy bool asSeries, // is as series double &M[] // target array for data ) { //--- filling M with current values of the indicator if(CopyBuffer(handle,bufer,start,number,M)<=0) return(false); ArraySetAsSeries(M,asSeries); return(true);
I think the problem here is that the CopyBufferAsSeries function works only for single buffer indicators like a simple moving average.
This means that I need to extend the function by further buffers, right?
- www.mql5.com
The error appears for the in which I call the function CopyBufferAsSeries.
And this is the CopyBufferAsSeries function:
I think the problem here is that the CopyBufferAsSeries function works only for single buffer indicators like a simple moving average.
This means that I need to extend the function by further buffers, right?
- 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,
I would like to build an EA using the Alligator indicator which consists of three moving averages. Therefore, I tried to copy the values of these moving averages into an array, as I've done before with the CCI indicator.
However, I get the error message: "Jaws" - parameter conversion not allowed.
So first I initialize the three arrays and the Alligator handle:
In the OnInit handle I create the indicator Alligator:
Then, within the OnTick handle I do the following to copy the indicator values to the three arrays:
Can maybe someone tell what I am doing wrong? Thanks!