MetaTrader 4 Build 529 beta released with new compiler - page 123

 
Wahoo:

On the same demo account (live chart) with the same set, trades open, no requotes...

Demo is not a tester. You need to write robust EAs so that they pass the tests even with requotes =)
 
komposter:
The demo is not a tester. You should write robust EAs so that they pass the tests even with requotes =)

There's something suspicious in there. Error 138. In the tester it usually appears when you try to open a pending order on the market, or vice versa - set a market order as a pending one.

 
Wahoo:

Am I the only one with re-quotes in the tester :)?

How to live further?

On the same demo account (live chart) with the same set of trades open, without requotes...

What do you have in your code in the opening function?
 

If you write the programme name in Russian, there are problems with the display of this name:

//+------------------------------------------------------------------+
//|                                            Из справки пример.mq4 |
//|                               Copyright 2013, Artyom A. Trishkin |
//|                       https://www.mql5.com/ru/users/artmedia70 |
//+------------------------------------------------------------------+

Does this remain, or is it possible to adjust it? Just for future reference.

 

The error must be in the help section under Functions --> Event handling functions. There is a line in the indicator example:

int bars=Bars(Symbol(),0);

The compiler does not know this function. iBars inserted to compile example.

 
Wahoo:


My SymbolSelect() does not work


Can you explain the physical meaning of your code?

The symbol is already selected if its chart is open, which is where this Expert Advisor works.

You cannot re-select already selected symbol. You cannot hide a symbol whose chart is open.

 
artmedia70:

The error must be in the help section under Functions --> Event handling functions. There is a line in the indicator example:

The compiler does not know this function. iBars has been inserted to compile the example.


Bars is a predefined variable in quadruple. It contains the number of bars of the current symbol-period, on the chart of which the expert-script indicator works.

We have already implemented the first version of the CopyXXX function. They are designed to be compatible with F5 (in fact, the semantics of the functions themselves should fit very well in F4).

Now we are thinking what to do with the Bars function, since we want maximum source code compatibility with MQL5.

 
stringo:

Bars is a predefined variable in foursquare. Contains the number of bars of the current symbol-period, on the chart of which the Expert Advisor-script works.

We have already implemented the first version of the CopyXXX function. They are designed to be compatible with F5 (in fact, the semantics of the functions themselves should fit very well in F4).

Now we are thinking what to do with the Bars function, since we want maximum source code compatibility with MQL5.

So in the future, Bars will not only be a predefined variable, but it will also be a function with the same name: Bars() ?
 

Hello!

We found the following problem.

We insert the block of switching from 4-digit quotes to 5-digit (the code works absolutely fine, it has been tested on dozens of Expert Advisors) :

int init()
{

/**************************/
/* ПЕРЕХОД НА 5-ЗНАК      */ 
/**************************/
    
   int _digits = (int)MarketInfo(Symbol(), MODE_DIGITS);
   if (_digits == 5 || _digits == 3)
   {
      TakeProfit  *= 10;
      Dist        *= 10;
      slip        *= 10;
      Step        *= 10;
      InitPipStep *= 10;
   }
   
/**************************/

From here you can see the following.

We bring up the input parameters of the Expert Advisor by pressing F7, everything is correct:

Press OK, then press F7 again:

Press OK, press F7 again:

Press OK, press F7 again:

And so on......

This bug does not disappear with updated builds. Appears with different users in the same way. Topic discussed here

 
artmedia70:

If you write the programme name in Russian, there are problems with the display of this name:

Does this remain, or is it possible to adjust it? Just for future reference.


You'd better write everything in English, if your code gets to a foreign trader, he won't understand anything...
Reason: