Hello,
Could you please help me to correct the following ea :
<CODE DELETED>
Please read some other posts before posting . . .
Please edit your post . . . please use the SRC button to post code: How to use the SRC button.
Hello,
Could you please help me to correct the following ea :
MHLong and MHshort are double type not bool . . . so this makes no sense . . .
if MHLong = true ; trade allowed if MHshort = true ; trade allowed
. . don't think you can just change the type from double to bool . . . that won't help, iCustom() returns a double.
thanks Raptor.
To be honest with my main problem for the moment is to try to understand how the information is linked between
double MHLong = iCustom(NULL,0,"Indicator",1000,1,0); double MHShort = iCustom(NULL,0,"Indicator",1000,0,0);
and
int i =0; while(i<=4) { Print(i); i++; }
I mean how the last shift of my MHLong and MHshort will be changed thanks to the reaserch in the 4 last candles.
I hope you will understand what I mean, English is not my mother tongue
thanks Raptor.
To be honest with my main problem for the moment is to try to understand how the information is linked between
and
I mean how the last shift of my MHLong and MHshort will be changed thanks to the reaserch in the 4 last candles.
I hope you will understand what I mean, English is not my mother tongue
So, my strategy is based on 4 indicators (RSI, MACD, volatilty and one indicator arrow.)
As you know,all indicators don't switch in the same time, in the same way.
That's the reason why I would keep in mind what was the last sense of the arrow.
Once the 3 other indicators go for a long trade, I would get the finale confirmation from arrow that's this trade is allowed.
Is it clearer for you ?
int i =0; while(i<=4) { Print(i); i++; double MHLong = iCustom(NULL,0,"Arrows_mh",1000,0,i); double MHShort = iCustom(NULL,0,"Arrows_mh",1000,1,i); }
Yes I do something with :
For the long :
if (MHLong != EMPTY_VALUE && MHLong != 0)&& (MHShort == 0 || MHShort == EMPTY_VALUE ) &&
for the short :
if (MHShort != EMPTY_VALUE && MHShort != 0)&& (MHLong == 0 || MHLong == EMPTY_VALUE ) &&
So, my strategy is based on 4 indicators (RSI, MACD, volatilty and one indicator arrow.)
As you know,all indicators don't switch in the same time, in the same way.
That's the reason why I would keep in mind what was the last sense of the arrow.
Once the 3 other indicators go for a long trade, I would get the finale confirmation from arrow that's this trade is allowed.
Is it clearer for you ?
Hello,
I am arrived to fix the problem about the icustom.
i++ was before the icustom. Please find below the solution.
int i =0; while(i<=4) { Print(i); double MHLong = iCustom(NULL,0,"Arrows_mh",1000,0,i); double MHShort = iCustom(NULL,0,"Arrows_mh",1000,1,i); i++; }
Something looks odd, when my ea run without this new indicator, ie positions are opened thanks rsi, macd et volatilitY:
if RSI = true && macd = true && volatilité = true && => trade allowed
I have a first trade at 15h30.
whereas, when my indicators MHShort and MHLong are added to the above one :
for the shorts if (MHShort ~ EMPTY_VALUE && MHShort ~ 0) for the long if (MHLong ~ EMPTY_VALUE && MHLong ~ 0)
my trade is opened at 14h00. It didn't take in account all the condition for the opening (in this case the volatility index was not enough strong).
Do you have an idea of what could happened ?

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hello,
Could you please help me to correct the following ea :
double MHLong = iCustom(NULL,0,"Indicator",1000,1,0);
double MHShort = iCustom(NULL,0,"Indicator",1000,0,0);
check 4last candles to know if indicator is long or short :
int i =0;
while(i<=4)
{
Print(i);
i++;
}
if MHLong = true ; trade allowed
if MHshort = true ; trade allowed
Thanks for your help