Download MetaTrader 5

What is the problem with this code ?

To add comments, please log in or register
Publish your application in the Market - 7 million potential clients will see it
jmfxtrader92
35
jmfxtrader92 2015.05.31 09:11 
class COrderType
   {
      private:
         double m_Ax; 
         double m_Ar; 
      
      public: 
      COrderType(double AR,double AX):m_Ax(AX),m_Ar(AR)
          {
            AX=iRSI(Symbol(),PERIOD_CURRENT,......);
            AR=iRSI(Symbol(),PERIOD_CURRENT,...);
          };  
      ~COrderType();    
          
      int getType(double Ax,double Ar);
            
      
   };

//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
int COrderType::getType(double Ax,double Ar)
   {     bool Buy;
         int dif;
         Ax=m_Ax;
         Ar=m_Ar;
                
         dif=Ax-Ar;
         if(dif>0)
                  {  
                     Buy=true;
                  }
                  
                if(dif<0)
                  {
                     Buy=false;
                  }    
                     
     return typ;    
   }

int rsi()
{  bool typ;
   double AR,AX;
   CMarketType rsi.getType(AR,AX);
             
   return typ;
}

Alain Verleyen
Moderator
30743
Alain Verleyen 2015.05.31 13:16  

Forum on trading, automated trading systems and testing trading strategies


Hello,

Please use the SRC button when you post code. Thank you.


This time, I edited it for you.


To add comments, please log in or register