MQL4 Reference Trade Functions OrderComment

MQL4 Help as One File:

OrderComment

Returns comment of the currently selected order.

string  OrderComment();

Returned value

Comment of the currently selected order.

Note

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

Example:

  string comment;
  if(OrderSelect(10,SELECT_BY_TICKET)==false)
    {
     Print("OrderSelect failed error code is",GetLastError());
     return(0);
    }
  comment = OrderComment();
  // ...