Unsupported filling mode - page 4

 
salitos #:

Or better yet..

Hi, I have the same problem with FX-PRO when I try to close a long position.

             MqlTradeRequest request;
             ZeroMemory(request);
           
             request.type         = ORDER_TYPE_SELL;
             request.price        = SymbolInfoDouble(Symbol(),SYMBOL_BID);                 
             request.action       = TRADE_ACTION_DEAL; // assigns the action type that will be executed by OrderSend
             request.position     = ticket; // assigns the position ticket
             request.symbol       = _Symbol; // assigns the name of the asset where the order will be sent to
             request.volume       = PositionGetDouble(POSITION_VOLUME); // assign the operation volume in lots
                         
             request.type_filling = 2 ;// assigns the execution type

             MqlTradeResult result;
             ZeroMemory(result);

             bool res =OrderSend(request,result);

I saw filling mode for EURUSD is 2, but it doesn't work.

Could you help me?

Thank you!

 

Well I spoke directly to FX PRO and the say that it's not possible to totally or partially close a position in strategy tester.

I seem quite strange.

Anyone having the same experience?

 

Trying to manually manage an order I see the Fill polic is "Immediate or Cancel". 

So I'm using this option in my experts and I seem it's works weel.