Why pending order delete it self

 

I add pending orders. Add two hours for expire. After it add the pending it delete it again after few seconds. Nothing in the code close any kind of order. Any idea why?

 In journal it just says pending order #... was deleted 

 
hasle1975:

I add pending orders. Add two hours for expire. After it add the pending it delete it again after few seconds. Nothing in the code close any kind of order. Any idea why?

 In journal it just says pending order #... was deleted 

Probably because your expiry was wrong ? How did you set it ?
 
Alain Verleyen:
Probably because your expiry was wrong ? How did you set it ?
No. I also tried without any. 
 
hasle1975:
No. I also tried without any. 
TimeClose = TimeCurrent() + 60* 60 * 1;
 
Alain Verleyen:
Probably because your expiry was wrong ? How did you set it ?
ticket=OrderSend(Symbol(),OP_BUYSTOP,Lotsize,PriceOpen,3,SL,LIMIT,"comment",5,TimeClose,clrGreen);
 
hasle1975:
ticket=OrderSend(Symbol(),OP_BUYSTOP,Lotsize,PriceOpen,3,SL,LIMIT,"comment",5,TimeClose,clrGreen);

Seems ok.

Next possibility, you have a code running which removes the pending.

What is written in the log ? (Experts and Journal).

Reason: