Errors, bugs, questions - page 1466

 
Комбинатор:
skype:login_contact?chat

it's better to put it that way )

skype:login_contact?call

 
Alexandr Bryzgalov:

it's better to put it that way )

skype:login_contact?call

I think I'm getting calls all the time. It's an auto-dialer from my profile, better change it to chat
 
The web terminal has lost its account. I registered my real account 3-4 days ago, everything was fine. And then I looked, no account. None at all. Doesn't ask for login or password, nothing in "Trading accounts" tab of MQL forum user profile...
 

wanted to find on the indicator stochastic last two inputs through the lines of levels up and down, three inputs are displayed normally and save their values and the fourth does not work correctly resets to zero when leaving the lower zone tell me what the error

//--- находим индекс бара вход в верхняя зону
   for(n=0; n<(Bars-1);n++)
     {
       if(iStochastic(Symbol(),0,5,3,3,MODE_SMA,1,0,n)<up_level && iStochastic(Symbol(),0,5,3,3,MODE_SMA,1,0,n-1) >up_level )
    //     break;
      UpLevel_1=n+1;
         
     }
//--- находим индекс бара второго ближайшего входа верхний уровень
  // for(n= UpLevel_1+1; n<(Bars-1);n++)
     {
      if(iStochastic(Symbol(),0,5,3,3,MODE_SMA,1,0,n)<up_level && iStochastic(Symbol(),0,5,3,3,MODE_SMA,1,0,n-1) >up_level )
      //   break;
      UpLevel_2=n+1;
      UpperPrice_2=iHigh(Symbol(),PERIOD_CURRENT,UpLevel_2);
     
     }
//--- находим индекс бара первого ближайшего входа нижний уровень
  for(n=0; n<(Bars-1);n++)
     {
     if(iStochastic(Symbol(),0,5,3,3,MODE_SMA,1,0,n)>dw_level && iStochastic(Symbol(),0,5,3,3,MODE_SMA,1,0,n-1) <dw_level )  
         break;
      DwLevel_1=n+1;
      LowerPrice_1=iLow(Symbol(),PERIOD_CURRENT,DwLevel_1);
     }
//--- находим индекс бара второго ближайшего входа нижний уровень
   for(n=DwLevel_1+1; n<(Bars-1);n++)
     {
       if(iStochastic(Symbol(),0,5,3,3,MODE_SMA,1,0,n)>dw_level && iStochastic(Symbol(),0,5,3,3,MODE_SMA,1,0,n-1) <dw_level )
         break;
      DwLevel_2=n+1;
      LowerPrice_2=iLow(Symbol(),PERIOD_CURRENT,DwLevel_2);
      Comment("вход верхняя зона" + DoubleToStr(UpLevel_1,0)+ "\n" + // работает правельно показания сохраняет
              "предыдущий вход верхняя зона" + DoubleToStr(UpLevel_2,0)+ "\n" + // работает правельно показания сохраняет
              " вход нижняя зона" + DoubleToStr(DwLevel_1,0)+ "\n" +  //работает неправельно обнуляет показания когда выходит из нижней зоны
              " предыдущий вход нижняя зона" + DoubleToStr(DwLevel_2,0)); // работает правельно показания сохраняет
     }
 
Mikhail Lebedev:

I wanted to find on the indicator stochastic last two inputs through the level lines up and down, three inputs are displayed normally and save their values and the fourth does not work correctly resets to zero when leaving the bottom zone tell me what is wrong

I made a quick script to give you an example:

//+------------------------------------------------------------------+
//|                                         FindStochasticSignal.mq4 |
//|              Copyright 2015, Artem A. Trishkin, Skype artmedia70 |
//|                       https://login.mql5.com/ru/users/artmedia70 |
//+------------------------------------------------------------------+
#property copyright "Copyright 2016, Artem A. Trishkin, Skype artmedia70"
#property link      "https://login.mql5.com/ru/users/artmedia70"
#property version   "1.00"
#property strict
#property script_show_inputs
//--- input parameters
input int      PeriodK=5;                       // Period %K Stochastic
int periodK=(PeriodK<1)?1:PeriodK;
input int      PeriodD=3;                       // Period %D Stochastic
int periodD=(PeriodD<1)?1:PeriodD;
input int      SlowingStc=3;                    // Slowing Stochastic
int slowingStc=(SlowingStc<1)?1:SlowingStc;
input ENUM_MA_METHOD MA_Method=MODE_SMA;        // MA Method Stochastic
input ENUM_STO_PRICE AppledPrice=STO_LOWHIGH;   // Appled Price Stochastic
input double LevelUP=70.0;                      // Up level Stochastic
input double LevelDN=30.0;                      // Down level Stochastic
input int      NumberCross=4;       // Number of Cross stochastics level
int numberCross=(NumberCross<1)?1:NumberCross;
//--- Arrays
double MassiveCrossUP[][2];
double MassiveCrossDN[][2];
MqlRates rates[];
//+------------------------------------------------------------------+
//| Script program start function                                    |
//+------------------------------------------------------------------+
void OnStart()
  {
//---
   int bars=iBars(Symbol(),Period());
   if(CopyRates(Symbol(),PERIOD_CURRENT,1,bars-1,rates)>0) {
      ArraySetAsSeries(rates,true);
      int nup=0, ndn=0;
      ArrayResize(MassiveCrossUP,nup,numberCross);
      ArrayResize(MassiveCrossDN,ndn,numberCross);
      for(int i=1; i<Bars; i++) {
         double StochMain0=GetDataSTO(Symbol(),Period(),periodK,periodD,slowingStc,MA_Method,AppledPrice,MODE_MAIN,i);
         double StochMain1=GetDataSTO(Symbol(),Period(),periodK,periodD,slowingStc,MA_Method,AppledPrice,MODE_MAIN,i+1);
         if(nup>numberCross && ndn>numberCross) break;
         if(StochMain0<LevelUP && StochMain1>=LevelUP) {
            nup++;
            if(nup<=numberCross) {
               ArrayResize(MassiveCrossUP,nup);
               MassiveCrossUP[nup-1][0]=int(rates[i].time);
               MassiveCrossUP[nup-1][1]=rates[i].high;
               }
            }
         if(StochMain0>LevelDN && StochMain1<=LevelDN) {
            ndn++;
            if(ndn<=numberCross) {
               ArrayResize(MassiveCrossDN,ndn);
               MassiveCrossDN[ndn-1][0]=int(rates[i].time);
               MassiveCrossDN[ndn-1][1]=rates[i].low;
               }
            }
         }
      }
   //---
   string text_up_crossing="Пересечения сверху-вниз:\n", text_dn_crossing="Пересечения снизу-вверх:\n";
   for(int i=0; i<ArrayRange(MassiveCrossUP,0); i++) {
      string date_cross=TimeToString(int(MassiveCrossUP[i][0]));
      string value_cross=DoubleToString(MassiveCrossUP[i][1],Digits());
      string txt_i="\n"+IntegerToString(i+1)+"-е пересечение уровня "+DoubleToString(LevelUP,1)+", время бара "+date_cross+", цена High свечи: "+value_cross;
      text_up_crossing+=txt_i;
      }
   text_up_crossing+="\n====================\n";
   for(int i=0; i<ArrayRange(MassiveCrossDN,0); i++) {
      string date_cross=TimeToString(int(MassiveCrossDN[i][0]));
      string value_cross=DoubleToString(MassiveCrossDN[i][1],Digits());
      string txt_i="\n"+IntegerToString(i+1)+"-е пересечение уровня "+DoubleToString(LevelDN,1)+", время бара "+date_cross+", цена Low свечи: "+value_cross;
      text_dn_crossing+=txt_i;
      }
   Comment(text_up_crossing+text_dn_crossing);
  }
//+------------------------------------------------------------------+
double GetDataSTO(string sy, int timeframe, int k_period, int d_period, int slowing, ENUM_MA_METHOD ma_method, ENUM_STO_PRICE price_field, int mode, int pos) {
   return(iStochastic(sy,timeframe,k_period,d_period,slowing,ma_method,price_field,mode,pos));
}
//+------------------------------------------------------------------+
 
Thanks for the script so far it looks like higher mathematics for a first grader I have not yet learned how to work with arrays. I found a mistake in my code had to insert other bar data in the loop and everything worked as it should
for(n=1; n<(Bars-2);n++)
 

I cannot get the new chart window to open at least halfway. When I right click on any instrument in the Market Watch window and select the "Chart Window" command, the chart opens undersized:

Graph at half size

How can I overcome this?

 
Karputov Vladimir:

I can't get the new chart window to open at least halfway.

I'm sure the developers will fix it.

In the meantime, it is necessary to have another chart of any instrument in a collapsed state. That is, you open USDJPY, manually expand it, and then manually minimize it. After that, you can open any desired chart and it will be in the full window.

You probably already know this.

 

In the latest builds of MT4 when using the portable mode there is no possibility to start MetaEditor - I wrote to the service desk, but there was no comprehensible answer.

If you run the exe itself in the folder with MT4, MetaEditor is loaded with environment in the folder AppData for Windows, if you press "change expert" in the terminal, the same thing happens, and before it was loaded from the folder, where the terminal was launched in the portable mode.

 

Log of a single run of an empty Expert Advisor in the MT4 tester using opening prices:

112972 tick events (113071 bars, 225205 bar states) processed in 0:00:00.016 (total time 0:00:05.039)

You can see from the log that the EA itself passes the history in zero time. It takes five seconds to prepare historical data (a little over 100K bars). This has never happened before.

It works 100% of the time. MT4 build 950, Windows7 SP1 x64.

Can you advise which extreme build does not suffer from this ailment. DOWNGRADE is required.