Please advise on Correct TP and SL

 

Dear experts,

Would you please advise on how I could improve the execution accuracy of the following orders:


Problem: Some of the orders are left unfilled, i.e. "The 2" position hits its stop-loss at the level of "The 4" but "The 4" positions are not opening and sometimes "The 2" closes but "The 4" are not opened at all.

Similar thing with the TPs and SLs...

"

// The 2

OrderSend(Symbol(),OP_BUYSTOP,0.02,Bid+0.001,3,0.0,Bid+0.002,"v1b",0,0,CLR_NONE);
OrderSend(Symbol(),OP_SELLLIMIT,0.02,Bid+0.001,3,Bid+0.003,0.0,"v1b",0,0,CLR_NONE);


// The 4

OrderSend(Symbol(),OP_BUYSTOP,0.04,Bid+0.002,3,0.0,Bid+0.003,"v1b",0,0,CLR_NONE);
OrderSend(Symbol(),OP_SELLLIMIT,0.04,Bid+0.002,3,0.0,0.0,"v1b",0,0,CLR_NONE);
 

"

The execution of the orders was improved by adding the spread to the Bid of the Limit orders i.e., but the reason behind it is not fully clear...and The TP and SL are the biggest issue...


OrderSend(Symbol(),OP_BUYSTOP,0.0392,Bid+0.002,3,0.0,Bid+0.003,"v1b",0,0,CLR_NONE);
OrderSend(Symbol(),OP_SELLLIMIT,0.04,Bid+0.002,3,0.0,0.0,"v1b",0,0,CLR_NONE);

Any kind of help and wisdom is much appreciated!


"
 
Petercho: Would you please advise on how I could improve this Martingale code

Yes, stop using it.
          Martingale, guaranteed to blow your account eventually.

 
whroeder1:

Yes, stop using it.
          Martingale, guaranteed to blow your account eventually.

:)
 
Martingale is a DEFINITE winning strategy, provided you have infinite amount of money supply and infinite time. Do you have this? I don't recommend using Martingale in these days of non-trending market.
 
Sarita Maru:
Martingale is a DEFINITE winning strategy, provided you have infinite amount of money supply and infinite time. Do you have this? I don't recommend using Martingale in these days of non-trending market.
Thank you, would you please share your opinion on how the orders could be made so that they are executed simultaneously, without a lag to each other?
Reason: