Check closely your magic number handling
extern int Magicnumber1=2;
OrderSend(Symbol(),OP_BUY,Lots,Ask,3,Ask-Stoploss*Point,Ask+Takeprofit*Point,"manifestation",1,0,Green);
OrderSend(Symbol(),OP_SELL,Lots,Bid,3,Bid+Stoploss*Point,Bid-Takeprofit*Point,"manifestation",1,0,Green);
if(OrderMagicNumber()==Magicnumber1) ... close
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
Hi,
i want my ea to close a buy order when my macd1 is less than macd2, and it should close a sell order if macd1 is greater than macd 2, but it does not,it closes the opened orders only at take profit and stop loss alone.
please help me .
the code as been attached. thanks.