Ajuda para actualizar para MetaTrader 5 sem perdas - página 6

 
Serj74 :
Muito obrigado.
O segundo está pronto, lamento ter demorado tanto tempo que não consegui chegar ao computador durante uma semana.
Arquivos anexados:
macd-rsi.mq5  7 kb
 
vdv2001 :
O segundo está pronto, lamento ter demorado tanto tempo que não consegui chegar ao meu computador durante uma semana.
Obrigado
 

Para vdv2001

Talvez seja demasiado tarde, mas mesmo assim gostaria de lhe pedir que traduzisse estes três indicadores para MKL 5, dois deles feitos por Rosh. Infelizmente, eu próprio sou um completo idiota na programação.

Arquivos anexados:
 
Além disso, existe um grupo de indicadores para o sistema de negociação ASTTREND (talvez se lembre de quando era popular), se não recusar, posso enviar-lhe a si e a eles para transferir para MKL 5 (existem 6 indicadores, três do principal e o restante carácter de serviço)
 
vdv2001:
O segundo está pronto, lamento ter demorado tanto tempo que não consegui chegar ao meu computador durante uma semana.
Provavelmente deveria ter escrito ao estilo de uma resposta ao posto relevante. Em caso afirmativo, por favor tome nota dos meus dois posts anteriores. obrigado antecipadamente pela sua atenção
 

  iBarBegin = iBarShift(NULL, 0, dtTimeBegin);
  iBarEnd = iBarShift(NULL, 0, dtTimeEnd);
  dPriceHigh = High[Highest(NULL, 0, MODE_HIGH, iBarBegin-iBarEnd, iBarEnd)];
  dPriceLow = Low [Lowest (NULL, 0, MODE_LOW , iBarBegin-iBarEnd, iBarEnd)];

Como escrevo este código no MT5?

Encontrei o procedimento iBarShift no fórum, mas o copyleader jura na função TFMigrate que ele não existe:

int iBarShift(string symbol,
                  int tf,
                  datetime time,
                  bool exact=false)
  {
   if(time<0) return(-1);
   ENUM_TIMEFRAMES timeframe=TFMigrate(tf);
   datetime Arr[],time1;
   CopyTime(symbol,timeframe,0,1,Arr);
   time1=Arr[0];
   if(CopyTime(symbol,timeframe,time,time1,Arr)>0)
     {
      if(ArraySize(Arr)>2) return(ArraySize(Arr)-1);
      if(time<time1) return(1);
      else return(0);
     }
   else return(-1);
  } 

 
eminsk:

  iBarBegin = iBarShift(NULL, 0, dtTimeBegin);
  iBarEnd = iBarShift(NULL, 0, dtTimeEnd);
  dPriceHigh = High[Highest(NULL, 0, MODE_HIGH, iBarBegin-iBarEnd, iBarEnd)];
  dPriceLow = Low [Lowest (NULL, 0, MODE_LOW , iBarBegin-iBarEnd, iBarEnd)];

Como escrevo este código no MT5?

Encontrei o procedimento iBarShift no fórum, mas o copyleader jura na função TFMigrate que ele não existe:

int iBarShift(string symbol,
                  int tf,
                  datetime time,
                  bool exact=false)
  {
   if(time<0) return(-1);
   ENUM_TIMEFRAMES timeframe=TFMigrate(tf);
   datetime Arr[],time1;
   CopyTime(symbol,timeframe,0,1,Arr);
   time1=Arr[0];
   if(CopyTime(symbol,timeframe,time,time1,Arr)>0)
     {
      if(ArraySize(Arr)>2) return(ArraySize(Arr)-1);
      if(time<time1) return(1);
      else return(0);
     }
   else return(-1);
  } 

Ver MQL4 a MQL5 Transição
 

Por favor, reescrever o indicador MultiInstrumento ou similar para sobreposição de uma tabela de instrumentos em outra.


 

Indicadores muito necessários, é possível fazer algo semelhante em mt5?

Arquivos anexados:
ind.rar  3 kb
 

Процедуру iBarShift я нашел на форуме, но копилятор ругается на функцию TFMigrate что она не существует:

ENUM_TIMEFRAMES TFMigrate(int tf){switch(tf) { case 0: return(PERIOD_CURRENT);   case 1: return(PERIOD_M1);      case 5: return(PERIOD_M5);   case 15: return(PERIOD_M15);
                                               case 30: return(PERIOD_M30);      case 60: return(PERIOD_H1);     case 240: return(PERIOD_H4); case 1440: return(PERIOD_D1);
                                               case 10080: return(PERIOD_W1);    case 43200: return(PERIOD_MN1); default: return(PERIOD_CURRENT);}}
lá vai você.
Razão: