Errors, bugs, questions - page 2841

 
Alexandr Nikolaev:

Did you read my post carefully and? I purposely did not complicate the code with different normalisations and checks. I always do that in my EAs. You see that in the code there are attempts to open an order without SL and TP? I specifically registered such attempts, but they didn't work. The purpose of this EA is not to open orders as it should be but to make attempts to at least make some errors and it seems to be 0 attempts here.

Please don't litter the thread. There is an article on how to publish your EA on the market. All it says is the minimum requirements. The rest is just your ignorance of the subject. Above rightly said - it's early days.

 
Alexandr Nikolaev:

Did you read my post carefully and? I purposely did not complicate the code with different normalisations and checks. I always do that in my EAs. You see that in the code there are attempts to open an order without SL and TP? I specifically registered such attempts, but they didn't work. The purpose of this EA is not to open orders as it should be but to make attempts to at least make some errors and it seems to be 0 attempts in this case.

The purpose of market validator is not to let such codesthrough without check... Otherwise, the market would be flooded with low-quality codes...

Code doesn't pass validation? Read this message. It doesn't pass again ? Read it again...

 
Alexandr Nikolaev:

It's not about the lot, I would put any lot, and normalise the lot, and there would be errors, but here it doesn't swear at anything, except that there are no trades.

https://www.mql5.com/ru/forum/296801/page15#comment_17812974
With funds of 1 dollar there will be no trades. This is what the validator says.
And in general, the topic is correct to move.

Замучила ошибка there are no trading operations
Замучила ошибка there are no trading operations
  • 2020.07.30
  • www.mql5.com
Не первый день пытаюсь понять природу ошибки there are no trading operations, которая появляется независимо от того, прописываю я в робота кучу про...
 

Noticed one unpleasant thing, didn't log in or install the terminal all evening yesterday - wanted to check why my browser was changing?

in the first picture before logging in and installing the terminal.

in the second picture installed the terminal and visited the site - and my browser has changed, how to fix it? and what can it be?

---------------------------------------------

(Browser is a window to the World - and how, I do not want that the whole World, come without asking for my space. )

Files:
m8lv.PNG  873 kb
aerb_2.PNG  138 kb
 
SanAlex:

Noticed one unpleasant thing, didn't log in or install the terminal all evening yesterday - wanted to check why my browser was changing?

in the first picture before logging in and installing the terminal.

in the second picture installed the terminal and visited the site - and my browser has changed, how to fix it? and what can it be?

---------------------------------------------

(Browser is a window to the World - and how, I do not want that the whole World, come without asking for my space. )

Repeated - installation to the first System Restore point , and went to the Browser settings and updated it.

- It turned out that the Browser was making these changes itself. So mt5 has nothing to do with it and neither does the Site.

- I apologise to the website for my doubts.

Files:
15vvcg.PNG  116 kb
 

Got this when changing trading accounts

2020.09.02 18:55:24.767 VR Watch list and linker (NMTP.MM,H1)   Access violation at 0x00007FF8622C72A6 write to 0x0000000000000024
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C71E0 803 D21E2150000    cmp        byte [rip+0x15e221], 0x0
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C71E7 0 F95C0            setnz      al
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C71EA C3                ret        
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)   
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C71EB CC                int3       
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7200 48895 C2418        mov        [rsp+0x18], rbx
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7205 55                push       rbp
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7206 56                push       rsi
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7207 57                push       rdi
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7208 4154              push       r12
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C720A 4155              push       r13
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C720C 4156              push       r14
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C720E 4157              push       r15
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7210 4881 ECA0000000    sub        rsp, 0xa0
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7217 488 B05C2621700    mov        rax, [rip+0x1762c2]
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C721E 4833 C4            xor        rax, rsp
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7221 4889842490000000  mov        [rsp+0x90], rax
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7229 654 C8B2C25300000  mov        r13, [gs:0x30]
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                                  00
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7232 488 D05BF821500    lea        rax, [rip+0x1582bf]
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7239 4032 ED            xor        bpl, bpl
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C723C 89542448          mov        [rsp+0x48], edx
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7240 33 F6              xor        esi, esi
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7242 40886 C2440        mov        [rsp+0x40], bpl
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7247 4 C896C2450        mov        [rsp+0x50], r13
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C724C 488 BD9            mov        rbx, rcx
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C724F 448 BE6            mov        r12d, esi
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7252 483 BC8            cmp        rcx, rax
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7255 0 F8438010000      jz         dword 0x7ff8622c7393
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)   
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C725B 403835 A6E11500    cmp        [rip+0x15e1a6], sil
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7262 0 F859B010000      jnz        dword 0x7ff8622c7403
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)   
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7268 3935 BAE11500      cmp        [rip+0x15e1ba], esi
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C726E 0 F855D010000      jnz        dword 0x7ff8622c73d1
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)   
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7274 4038357 DDC1500    cmp        [rip+0x15dc7d], sil
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C727B 488 D3D7EDC1500    lea        rdi, [rip+0x15dc7e]
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7282 480 F45FE          cmovnz     rdi, rsi
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7286 48397318          cmp        [rbx+0x18], rsi
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C728A 0 F84D1000000      jz         dword 0x7ff8622c7361
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)   
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7290 488 B03            mov        rax, [rbx]
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7293 4883 F8FF          cmp        rax, 0xff
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C7297 0 F84D1000000      jz         dword 0x7ff8622c736e
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)   
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C729D 448 BFE            mov        r15d, esi
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C72A0 4883 F8FF          cmp        rax, 0xff
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C72A4 7403              jz         0x7ff8622c72a9
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)   
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)      crash -->  00007 FF8622C72A6 FF4024            inc        dword [rax+0x24]
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C72A9 4 C8B7318          mov        r14, [rbx+0x18]
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C72AD 4 C8D2D44821500    lea        r13, [rip+0x158244]
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C72B4 BD22170000        mov        ebp, 0x1722
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C72B9 E872890300        call       0x7ff8622ffc30  ; RtlGetCurrentTransaction (ntdll.dll)
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C72BE 85 C0              test       eax, eax
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)                 00007 FF8622C72C0 0 F855E0B0A00      jnz        dword 0x7ff862367e24
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)   
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)   
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)   00: 0x00007FF8622C72A6
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)   01: 0xFFFFFFFFFFFFFFFF
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)   02: 0x000002351BFE1278
2020.09.02 18:55:24.771 VR Watch list and linker (NMTP.MM,H1)   
 
Can you please tell me if the Expert Advisor can refer to other symbols as part of its work on one symbol? For example, my Expert Advisor is running on AUD/usd, and I want to implement analysis inside its code execution, e.g. Gold, which causes the robot to make decisions about further actions on aud/usd trades. This is an example. I want to make calculations based on the major currencies within one EA, say, seven of them. I.e., I want to try implementing inter-character analysis. The news releases in one country, the price jumps and based on such changes, a decision is made to open orders for 1-7 pairs. Theoretically, this is possible without the use of external programs and services within MQL4? How about MQL5?
 
Denis Diakonov:
Can you please tell me if an EA can access other symbols while working on one symbol? For example, my Expert Advisor has been started on AUD/usd and I want to be able to add in its code analysis, for example, Gold, which will make my robot make decisions about further actions on aud/usd trades. This is an example. I want to make calculations based on the major currencies within one EA on one chart. I.e., I want to try implementing inter-character analysis. The news releases in one country, the price jumps and on the basis of these changes, a decision is made to open orders for 1-7 pairs. Theoretically, this is possible without the use of external programs and services within MQL4? How about MQL5?

There are no limitations for MQL5 Expert Advisors: working on one symbol, MQL5 Expert Advisors can freely analyze OHLC from other people's timeframes and symbols, and can freely open positions and place pending orders on other symbols.

 

I'll ask again about the "hidden method calling" error. There is a code:

class A
{
  public:
    virtual void extend(int x) = 0; // if removed in both classes - no warning
    virtual void extend(string x)
    {
    }
};

class B: public A
{
  public:
    virtual void extend(int x) override
    {
    }
};

void OnStart()
{
  B b;
  b.extend(""); // deprecated bla-bla-bla
}

Explain why a method with a parameter of type string is hidden even though it is public and not overridden? Why do I have to override it in a derived class? And why does the warning disappear if I remove an overloaded method with a different parameter type?

 
Stanislav Korotky:

1. Explain why a method with a parameter of type string is hidden, even though it is public and not overridden?
2. Why do I have to override it in a derived class?
3. And why does the warning disappear if I remove an overloaded method with a different parameter type?

1. C++ standard for selecting an overloaded function (overloaded class method).
The first matching function is searched by name, not by signature, starting from the current class and going into each base class.

2. C++ standard. It is necessary to either explicitly override or use using declaration.
In MQL, methods and fields of the base class are "directly available" from the derived classes

.
In fact, the inheritance behavior in MQL is similar to using declaration for each basic field and method in C++.
In MQL on the one hand they add freedom, but on the other hand they require the same things as in C++, but provide absolutely no methods of getting around ridiculous warnings from the user's point of view.


Reason: