In Backtest or Demo Account Order is being executed by the last price

 

Hi all,

    I was surprised when I find out that in backtest and in demo accounts orders are being executed by the last price instead of bid/ask of the Symbol. Does MT5 works like that? Anyway I can change it to be executed by the bid/ask? 

   I tried with TRADE_ACTION_DEAL and TRADE_ACTION_PENDING. In both of them was executed by last price. 

 

 

Regards,

Roberto Faucz 

 
Roberto Faucz:

Hi all,

    I was surprised when I find out that in backtest and in demo accounts orders are being executed by the last price instead of bid/ask of the Symbol. Does MT5 works like that? Anyway I can change it to be executed by the bid/ask? 

   I tried with TRADE_ACTION_DEAL and TRADE_ACTION_PENDING. In both of them was executed by last price. 

 

 

Regards,

Roberto Faucz 

Probably a bug ? which build are you using ? which symbol and broker ?