Download MetaTrader 5

Experts: cheduecoglioni

To add comments, please log in or register
Automated-Trading
Admin
111013
Automated-Trading  

cheduecoglioni:

The EA waits for a TP or SL to trigger, and then opens a position in the opposite direction. It checks if there is enough money before sending a trade request. OnTradeTransaction.

Author: Vladimir Karputov

Mohamad Kolor
31
Mohamad Kolor  

Hello my friend , Vladimir.

The condition was very interesting to me:

            if( m_trade.ResultDeal()==0 )
              {
               Print("Buy -> false. Result Retcode: ",m_trade.ResultRetcode(),
                     ", description of result: ",m_trade.ResultRetcodeDescription());
              }


Following conditions are right for  OrderSendAsync() function or Pending Order ?


            if( m_trade.ResultDeal()==0  ||  m_trade.ResultOrder()==0 )
              {
               Print("Buy -> false. Result Retcode: ",m_trade.ResultRetcode(),
                     ", description of result: ",m_trade.ResultRetcodeDescription());
              }

To add comments, please log in or register