Errors, bugs, questions - page 547

 
SwInGeR:
Can you tell me why there is no possibility to download Experts? I cannot even download the demo or free versions. I press "download" and nothing happens, I checked in Chrome and IE.

Can't download from Codebase or Market? The Market is not fully up and running yet - just getting ready, but Codebase is downloading fine.

If you work through proxy, check if you have proxy settings in Internet Explorer.

 
Renat:

Can't download from Codebase or Market? Market is not fully up and running yet - just getting ready, but from Codebase it's downloading fine.

If working via proxy, check proxy settings in Internet Explorer.

Through Market (both from program and browser), from CodeBase is downloading.
 

To the developers.

Here's what I found in the Anglian help.

ENUM_CHART_PROPERTY_DOUBLE

ID

Description

Property Type

CHART_SHIFT_SIZE

The size of the zero bar indent from the right border in percents

double (from 10 to 50 percents)

CHART_FIXED_MAX

Fixed chart maximum

double

CHART_FIXED_MIN

Fixed chart minimum

double

CHART_POINTS_PER_BAR

Scale in points per bar

double

CHART_PRICE_MIN

Chart maximum

double r/o modifier - subwindow number

CHART_PRICE_MAX

Chart minimum

double r/o modifier - subwindow number

 
Interesting:

To the developers.

Here's the Anglican reference.


What exactly is the question? https://www.mql5.com/ru/docs/constants/chartconstants/enum_chart_property#enum_chart_property_double
Документация по MQL5: Стандартные константы, перечисления и структуры / Константы графиков / Свойства графиков
Документация по MQL5: Стандартные константы, перечисления и структуры / Константы графиков / Свойства графиков
  • www.mql5.com
Стандартные константы, перечисления и структуры / Константы графиков / Свойства графиков - Документация по MQL5
 

CHART_PRICE_MIN

Chart maximum

CHART_PRICE_MAX

Chart minimum

 
sergeev:

CHART_PRICE_MIN

Chart maximum

CHART_PRICE_MAX

Chart minimum


Very interesting.... Thanks, we will check other languages too.
 
Please tell me in a nutshell what command to close an order with. Or give me a link to an article. I don't need any complicated code, just a couple of lines.
 
progeon:

Please tell me in a nutshell what command to close an order with. Or give me a link to an article. You don't need a complex code, just a couple of lines.
In MT5, we do not open and close orders but positions. To close an open position, you should send a trade request to open an opposite position with the same volume. See MQL5 Reference Guide / Standard constants, enumerations and structures / Data structures / Structure of a trade request
 


On October 20, I downloaded MQL5 Strategy Tester Agent from cloud.mql5.com. With the default setting of the number of agents on a single-processor computer, 2 agents have been created, and in the configurator on the Services tab, the number of recommended agents to install and set is 1. The build at installation was 507, updated to 523.

 

Good night . I've just started to look into it closely. It seems to be an obvious bug. I cite the code below, if I comment on one line below (it is marked) then it seems to work - I do not understand what the problem is. The situation can be avoided by specifying an explicit size for the Raznica[] array. I did not find anything in the documentation on this subject.

#property copyright "Copyright 2011, MetaQuotes Software Corp."
#property link      "http://www.mql5.com"
#property version   "1.00"
#include <MovingAverages.mqh>
#property indicator_chart_window
#property indicator_buffers 2
#property indicator_plots   2
//--- plot BaseMa
#property indicator_label1  "BaseMa"
#property indicator_type1   DRAW_LINE
#property indicator_color1  clrRed
#property indicator_style1  STYLE_SOLID
#property indicator_width1  1
//--- plot MaForMa
#property indicator_label2  "MaForMa"
#property indicator_type2   DRAW_LINE
#property indicator_color2  clrBlue
#property indicator_style2  STYLE_SOLID
#property indicator_width2  1
//--- input parameters
input int      MaPeriod=10;// период усреднения
input ENUM_MA_METHOD  Method=MODE_SMA ; // метод сглаживания                 
//--- indicator buffers
double         BaseMaBuffer[];
double         MaForMaBuffer[];
int            hiMa   ;
//+------------------------------------------------------------------+
//| Custom indicator initialization function                         |
//+------------------------------------------------------------------+
int OnInit()
  {
//--- indicator buffers mapping
   SetIndexBuffer(0,BaseMaBuffer,INDICATOR_DATA);
   SetIndexBuffer(1,MaForMaBuffer,INDICATOR_DATA);
   ArraySetAsSeries(BaseMaBuffer,true) ;
   ArraySetAsSeries(MaForMaBuffer,true) ;
   switch(Method)
      {
         case (MODE_SMA):
            hiMa=iMA(NULL,0,MaPeriod,0,MODE_SMA,PRICE_CLOSE) ;
            break ;
         case (MODE_EMA):
            hiMa=iMA(NULL,0,MaPeriod,0,MODE_EMA,PRICE_CLOSE) ;
            break ;
         case (MODE_SMMA) :
            hiMa=iMA(NULL,0,MaPeriod,0,MODE_SMMA,PRICE_CLOSE) ;
            break ;
         case (MODE_LWMA) :
            hiMa=iMA(NULL,0,MaPeriod,0,MODE_LWMA,PRICE_CLOSE) ;
      }
   
//---
   return(0);
  }
//+------------------------------------------------------------------+
//| Custom indicator iteration function                              |
//+------------------------------------------------------------------+
int OnCalculate(const int rates_total,
                const int prev_calculated,
                const int begin,
                const double &price[])
  {
  
    double ima[],Raznica[];
    int ended ,i,j,aaa;
    if (rates_total < MaPeriod - 1)
    return(0);   
    if (prev_calculated == 0)
       ended=rates_total-MaPeriod-10 ;
    else 
       ended=rates_total-prev_calculated-1 ;
    ArraySetAsSeries(price,true) ;
    for ( i=0; i < ended;  i++)
      {
         CopyBuffer(hiMa,0,i,1,ima) ;
         BaseMaBuffer[i]=ima[0] ;
         
      }
//-------------------------------------------------------------------------------
    for(i=0 ;i< ended ;i++)
      {
         for( j=0 ;j< 10 ;j++)
            {
               Raznica[j]=0;// ради прикола попробуйте закоментировать эту строку 
            }
         MaForMaBuffer[i]=2*BaseMaBuffer[i]-price[i];   
      }   
   return(rates_total);
  }
//+------------------------------------------------------------------+