How can I get the order comment of an executed order?

 

Hello guys,

I have two questions about this code:

1) why do I receive two notifications?

2) instead of the order comment I get nothing. Why?

//+------------------------------------------------------------------+
//| TradeTransaction function                                        |
//+------------------------------------------------------------------+
void OnTradeTransaction(const MqlTradeTransaction& trans,
                        const MqlTradeRequest& request,
                        const MqlTradeResult& result) {

   if (trans.order_state==ORDER_STATE_FILLED) {
      SendNotification(trans.symbol+" filled. Comment: "+request.comment);
   }
}

Thank you!

 
Documentation on MQL5: Constants, Enumerations and Structures / Trade Constants / Position Properties
Documentation on MQL5: Constants, Enumerations and Structures / Trade Constants / Position Properties
  • www.mql5.com
Position Properties - Trade Constants - Constants, Enumerations and Structures - MQL5 Reference - Reference on algorithmic/automated trading language for MetaTrader 5
Reason: