Hi,
I a newbie in MQL4, and I need some help.
How to send an order when an indicator change its color? I`ve studied about that but I`ve not found the information. I`d like to use the color of an indicator as an entrance parameter to create a condition to send an order. Could anyone help me, please?
Regards,
find out which buffer is linked to which color and then you can use it to determine entry criteria.
hi,
Try to use this function ObjectGet("object_name", OBJPROP_COLOR);
Indicator may not use objects at all. 23510 is right. After buufers are linked to colors use iCustom().
Indicator may not use objects at all. 23510 is right. After buufers are linked to colors use iCustom().
Hi,
I trying to create an EA that uses the indicator "SR" attached. The entry condition should be as I said before: when the arrow from SR changes the color, I must enter the order.
Could you help me, please?
Regards,
Hi,
I trying to create an EA that uses the indicator "SR" attached. The entry condition should be as I said before: when the arrow from SR changes the color, I must enter the order.
Could you help me, please?
Regards,
This Ind. Uses 2 Buffers, each buffer has it's own color . So instead of asking about the color U can ask about it's Value.
If the value of 1st buffer is 0, the value of the 2nd buffer > 0, so U can use one IF on One buffer !!
if ( iCustom(Symbol(),TF,"SR",5,240,0,1) > 0 && iCustom(Symbol(),TF,"SR",5,240,0,1==0 ) {
/// Sell
}
else if ( iCustom(Symbol(),TF,"SR",5,240,0,1) == 0 && iCustom(Symbol(),TF,"SR",5,240,0,1>0 ) {
// Buy
}
This Ind. Uses 2 Buffers, each buffer has it's own color . So instead of asking about the color U can ask about it's Value.
If the value of 1st buffer is 0, the value of the 2nd buffer > 0, so U can use one IF on One buffer !!
if ( iCustom(Symbol(),TF,"SR",5,240,0,1) > 0 && iCustom(Symbol(),TF,"SR",5,240,0,1==0 ) {
/// Sell
}
else if ( iCustom(Symbol(),TF,"SR",5,240,0,1) == 0 && iCustom(Symbol(),TF,"SR",5,240,0,1>0 ) {
// Buy
}
I have an ea when I backtested it for the first time
It is quite fast, but now it takes forever .
Any particular setting I need to set?
Please advise.
- 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 a newbie in MQL4, and I need some help.
How to send an order when an indicator change its color? I`ve studied about that but I`ve not found the information. I`d like to use the color of an indicator as an entrance parameter to create a condition to send an order. Could anyone help me, please?
Regards,