Place An Order Without Stop Loss or Profit Target

 
Hi

I'm a bit new to this ... can anybody tell me how to place an order in a EA without a stop loss or profit tarket

Thanks

Paul
 
murfinp:
Hi

I'm a bit new to this ... can anybody tell me how to place an order in a EA without a stop loss or profit tarket

Thanks

Paul

very simple

In the OrderSend function, place value of Ask - 999 for stoploss and Ask + 999 for take profit (thats for buying long),
or Bid + 999 for stoploss and Bid - 999 for take profit (thats for selling short)

BUYING LONG : ticket=OrderSend(Symbol(), OP_BUY, Lots,Ask, 3, Ask - 999 * Point, Ask+TakeProfit*Point,"Text",16384,0,Green);
SELLING SHORT : ticket=OrderSend(Symbol(),OP_SELL,Lots,Bid,3,Bid+ 999 * Point, Bid-TakeProfit*Point, "Text",16384,0,Red);
 
yada0206:
murfinp:
Hi

I'm a bit new to this ... can anybody tell me how to place an order in a EA without a stop loss or profit tarket

Thanks

Paul

very simple

In the OrderSend function, place value of Ask - 999 for stoploss and Ask + 999 for take profit (thats for buying long),
or Bid + 999 for stoploss and Bid - 999 for take profit (thats for selling short)

BUYING LONG : ticket=OrderSend(Symbol(), OP_BUY, Lots,Ask, 3, Ask - 999 * Point, Ask+TakeProfit*Point,"Text",16384,0,Green);
SELLING SHORT : ticket=OrderSend(Symbol(),OP_SELL,Lots,Bid,3,Bid+ 999 * Point, Bid-TakeProfit*Point, "Text",16384,0,Red);
 
Thanks much appreciated
 
No , this is correctly

BUYING LONG :        ticket=OrderSend(Symbol(),OP_BUY,Lots,Ask,3,0,0,"Text",16384,0,Green);
SELLING SHORT :    ticket=OrderSend(Symbol(),OP_SELL,Lots,Bid,3,0,0,"Text",16384,0,Red);

 
Reason: