Strategy Tester issue

 

I have an Expert Adviser that is using iCustom to call a market supplied macd.

It works fine in the Strategy Tester while I am using default inputs, but there is trouble when I put the inputs into the iCustom parameters.

While in the tester,  the new inputs still enter trades on the Arrows as before. (Visual mode = on)

When I stop the tester, the screen does not populate with one macd indicator window, but with hundreds.

It appears that with extra inputs in the iCustom command, it draws a new indicator every time the EA cycles around the check loop.

Is this common, or does it sound like I have my programming wrong.

iCustom(NULL,0,"Market/MACDivergence MTF",2,1);        This line works, and draws only one indicator window when tester stopped.

iCustom(NULL,0,"Market/MACDivergence MTF",0,89,200,20,2,1); This line changes macd to 89, 200, 20 correctly,-

however when the tester stopped, there are multiple macd windows now open on the chart.

(The first parameter is an Input header, so I put 0 in its place, prior to 89,200,20.)

 
Pete318: (The first parameter is an Input header, so I put 0 in its place, prior to 89,200,20.)
  1. We can't know what your indicator's parameters are. There are no mind readers here.
  2. If you mean "input header" is a string, then pass a string.
 
whroeder1:
  1. We can't know what your indicator's parameters are. There are no mind readers here.
  2. If you mean "input header" is a string, then pass a string.

I Have attached a photo of the information I have. It includes 3 fields. The Data screen, which is reproduced in buffer screen. From this information I get the buffer (Arrow) trigger for the iCustom call.

Then there is the input screen from the indicator. These are usually put into iCuston in-order, after the indicator is named in the iCustom call, up to the inputs you want changed.

Therefor I put 0,89,200,20, between MACDivergence MTF and 2. (2 being an Arrow buffer)

The indicator is from the market, so only an .ex4 file which I cannot open.

another photo shows when it fails

I hope this gives enough information to work with.

Files:
 
Pete318:

I Have attached a photo of the information ....there is the input screen from the indicator. 

I found the problem.

The first input is a string as such:- "--------------------------------------------------------------"

So when I used a 0 (zero) to fill the position, it created a problem.

Solution is:- iCustom(NULL,0,"Market/MACDivergence MTF,"",89,200,20,2,1);

Not as in original post.

Thanks to anyone who had been researching it for me.