|
Hi,
I'm trying to make EA based on Resistance and Support.
If price brakes resistance and it is 5 pips over ... buy, etc.
My EA is only buying.
I'm using these codes:
double Resistance=iCustom(NULL, 0, "Support_Resistance",0,0,0);
double Support =iCustom(NULL, 0, "Support_Resistance",0,1,0);
//------------------------------------------------------------+
...
if (openprice_curr < Support-Distance*point)
{
OrderSend(Symbol(),OP_SELL,...
}
if (openprice_curr >= Resistance+ Distance*point)
{
OrderSend(Symbol(),OP_BUY,...
}
Thanks
Bongo
|