MQL4 Reference Trade Functions OrderCommission

OrderCommission

Returns calculated commission of the currently selected order.

double  OrderCommission();

Returned value

The calculated commission of the currently selected order.

Note

The order must be previously selected by the OrderSelect() function.

Example:

  if(OrderSelect(10,SELECT_BY_POS)==true)
    Print("Commission for the order 10 ",OrderCommission());
  else
    Print("OrderSelect failed error code is",GetLastError());