strategy tester error 134, and 138 - page 2

 
  if(t==0 && GD==0 && a==0 && ExecuteNow1==true && l[1]>0 && cl==0) tickx=OrderSend(Symbol(),OP_BUY,l[1],Ask,slp,0,0,GridCmnt+" L1",Magic);

Odd that you would get an error 130 with SL and TP set to 0. Can you post up your log messages?

 

   if(Digits==4 || Digits==2) {pip=Point; dig=Digits; spr=MarketInfo(Symbol(),MODE_SPREAD); slp=Slippage;}
  
   if(Digits==5 || Digits==3) {pip=Point*10; dig=Digits-1; spr=MarketInfo(Symbol(),MODE_SPREAD)*0.1; slp=Slippage*10;}

 What is the value of Slippage? Are you doing RefreshRates() before sending the order?

 

they are 76km long once EA starts :)

 

2017.02.09 15:36:37.508 2016.01.03 19:22:00  Tam EURUSD,M1: OrderSend error 138

2017.02.09 15:36:37.507 2016.01.03 19:21:00  Tam EURUSD,M1: OrderSend error 138

2017.02.09 15:36:37.506 2016.01.03 19:20:00  Tam EURUSD,M1: OrderSend error 138

2017.02.09 15:36:37.504 2016.01.03 19:19:00  Tam EURUSD,M1: OrderSend error 138

2017.02.09 15:36:37.093 TestGenerator: spread set to 30

2017.02.09 15:36:28.335 Expert Tam EURUSD,M1: loaded successfully

 

 

---------

slippage - 10

i checked slippage before even changed it to 100, same. 

 

RefreshRates() not used. But does it matter if error appears on strategy tester? 

 
gudruolis:

they are 76km long once EA starts :)

 

2017.02.09 15:36:37.508 2016.01.03 19:22:00  Tam EURUSD,M1: OrderSend error 138

2017.02.09 15:36:37.507 2016.01.03 19:21:00  Tam EURUSD,M1: OrderSend error 138

2017.02.09 15:36:37.506 2016.01.03 19:20:00  Tam EURUSD,M1: OrderSend error 138

2017.02.09 15:36:37.504 2016.01.03 19:19:00  Tam EURUSD,M1: OrderSend error 138

2017.02.09 15:36:37.093 TestGenerator: spread set to 30

2017.02.09 15:36:28.335 Expert Tam EURUSD,M1: loaded successfully

 

 

---------

slippage - 10

i checked slippage before even changed it to 100, same. 

 

RefreshRates() not used. But does it matter if error appears on strategy tester? 

What about your 130 error codes?

Try the RefreshRates() immediately before OrderSend

 
honest_knave: Odd that you would get an error 130 with SL and TP set to 0. Can you post up your log messages?
I've been getting that occasionally on FXCM (live/demo/1031) using my GUI. Obviously the stops are correct. Hitting the button again opens the order. So I'm thinking a requote (138) sometimes is reported as invalid stops (130.)
 
whroeder1:
I've been getting that occasionally on FXCM (live/demo/1031) using my GUI. Obviously the stops are correct. Hitting the button again opens the order. So I'm thinking a requote (138) sometimes is reported as invalid stops (130.)
Good to know, thank you.