![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
thx qjol and 7bit...
qjol, your method ==0.0 can open position buy after red arrow appear and continues open untill appear new arrow.. but i want after blue arrow open buy and not continues open....
so i change to ==1, but still can not too..
and i change a,c,e,g, can not too..
and 7bit..
your method using != EMPTY_VALUE, direct open position with arrow appear and continues to untill last bar.. almost all bar open postion..
using if (a != EMPTY_VALUE)
and using (a != EMPTY_VALUE && c != EMPTY_VALUE && e != EMPTY_VALUE && g!= EMPTY_VALUE) have same result..
i want to open buy after display blue arrow..
this blue arrow appear if:
w1 blue or red
d1 blue
h4 blue
h1 blue
i think the important is d1, h4 and h1 blue.. so the w1 even red, it can show blue arrow too.. because w1 rare change color, often red color..
a=up color -->w1
b=down color -->w1
c= up color -->d1
d= down color -->d1
e=up color -->h4
f=down color -->h4
g= up color -->h1
h= down color -->h1
is like that or not?
because i want open buy after blue arrow, i use code:
if ( a==00 || a !=0.0 && c==00 && e ==0.0 && g==0.0) --> display result on red arrow, not blue..
or using
( a==EMPTY_VALUE || a !=EMPTY_VALUE && c != EMPTY_VALUE && e != EMPTY_VALUE && g!= EMPTY_VALUE)
display result on all arrow..
so still wrong..
i have think about condition like this:
if(w1=blue or red and d1[1],h4[1],h1[1] =blue and d1[2] != d1[1] color or h4[2] != h4[1] color or h1[2] != h4[1] color), then open buy..
maybe like that the condition.. but how about the code?
thx.. :)
to tell you the truth, I did not told you exactly how to do it, just wanted to give you the idea how to do it
if so...
i only want to know about the value of this:
in below of chart,will see this indicator display...
w1 color color color color
d1 color color color color
h4 color color color color
h1 color color color color
d1 color= red
what this mean ?
a. c==00
b. c!=00
c. d==00
d. d!=00
e. c==EMPTY_VALUE
f. c!=EMPTY_VALUE
g. d==EMPTY_VALUE
h. d!=EMPTY_VALUE
which is the correct answer?
i dont c Different colors between W1 & D1 & ....
u nee to check any TF Separately
oh yes... thx boss qjol..
it's work..
yesterday using double a = iCustom(NULL, 0, "4BARS",0,1);
the first time, i test, i think that a is for period W1 function... so be confusious..
because the real the a is period H1..
and i am using your code like
so it more quickly, can know which function is for certain period... so no need many testing..
and i see buf 0 with 1 is only have opposite value..
so i only using w_a,d_a,h4_a,h1_a.
o ya, after testing backtest, the position can open normally, but in the log have
what is that means?
thx..
I am currently looking into it and I notice that I made a mistake
ok, here we go
If you put the indicator on 1H TF chart then
even using like that, the list in the log still :
i got some answer from forums babypips that said the error " testgenerator :unmatched data error" is not problem and not effect for position.. because it's caused by when the chart timeframe you are using for the test has prices which do not match those of the lowest timeframe chart. For instance if you are testing on the 15 minute chart and the 15 minute chart has a high of 1.2727 but the history data on your 1 minute chart at the same time does not reach the same high this causes the unmatched data error.
and about eurousd,h1 : unknown subwindow number -1, still not found the way of solve it..i don't know what that effect, if that does not have effect, so not problem..
but i see from my backtest result, there is 90% open based of condition, and other not open position even have touch based of condition...
is this problem caused by that error or not?
or every ea can not fully open position based of condition?
this mission almost complete..
hardyyanto:
....
and about eurousd,h1 : unknown subwindow number -1, still not found the way of solve it..i don't know what that effect, if that does not have effect, so not problem..
......I think...(but not positive) that you get that error if you are making an icustom call in the ea from an indicator that is looking to put objects onto the chart... but the indicator window can't be found... because you haven't loaded the indicator onto your chart. AFAIK, it doesn't impact your EA... but you may be better, if there are switches in the indicator externs to display the objects to make those false in your icustom call....as I say, not sure 100% but hth
V