Errors, bugs, questions - page 389

 
Integer:
I try to compile script by calling mql5.exe, the script uses an includnik - it doesn't compile. I remove the invoke of the inluder - it compiles. It compiles in editor with indicator.
Path to folder with subdirectories through /i:<path> you set?
 
mql5:
Do you set /i:<path> as the path to the folder with the injections?


Thanks, got it. I didn't.

 

More often than not, changing the parameter "maxbars in window", judging by the depth of history loaded via CopyOpen and other functions, immediately after MT reloading does not work for some reason and succeeds only for some seemingly arbitrary times.

Tell me, isn't there a function that would change the depth of history loading itself in online mode?

Within the standard tester, as I understand it, such a feature is implemented, and in the case of creating an alternative tester, it is also needed.
Документация по MQL5: Доступ к таймсериям и индикаторам / Bars
Документация по MQL5: Доступ к таймсериям и индикаторам / Bars
  • www.mql5.com
Доступ к таймсериям и индикаторам / Bars - Документация по MQL5
 

Question 2: Suppose we have an indicator window, to which indicator versions with different parameters are added.

In this case, scaling for each version will be performed separately and as a result, the scales of different versions will not coincide and overlap each other in case of discrepancy of the visible extrema.

The implementation of a single scaling, due to the absence of a scrolling event in this case, is extremely difficult, while the creation of an indicator, that would include several lines, is hampered by the absence of possibility to dynamically set their colours and the overall cumbersomeness of the code.

Alas, it is difficult to find simple ways to solve this issue within the existing model. Therefore, a question, is it possible to add the properties of a single scaling of all indicators that are placed in the window?

 
Why when a position is reversed (in/out), the order (trade) comment is not overwritten in the 'Comment' field of the position ? I tried to flip it by hand - same thing.
Документация по MQL5: Стандартные константы, перечисления и структуры / Торговые константы / Свойства сделок
Документация по MQL5: Стандартные константы, перечисления и структуры / Торговые константы / Свойства сделок
  • www.mql5.com
Стандартные константы, перечисления и структуры / Торговые константы / Свойства сделок - Документация по MQL5
 
Valmars:
Why, when a position is reversed (in/out), the order (trade) comment is not overwritten in the 'Comment' field of the position? I tried to do it manually - same thing.

The new position should be overwritten, as I understand it, which is the opposite of the initial position.

Out it goes out closing the initial position, the comment there goes out remains the same.

Although, of course, it would be better to change the comment in out, to make it clearer why the position has been closed.

 
Interesting:

The new position should be overwritten, as I understand it, which is the opposite of the initial position.

Out is the closing of the initial position, the comment there remains the same.

Although it is certainly advisable to change the comment on out to make it clearer why the position was closed.

The position stayed as it was but changed its direction. When opening a position, the comment is overwritten and so is the position itself. But it is not so for the reversal. The reason of the change is specified there. In the history of trades and orders, the comment is present. This is not the issue of MQL5-program but of the terminal since the field remains empty even in case of manual reversal with the comment specified.

I think it should be filled in from the order. Otherwise it's not clear who changed the position; EA or manually (visually, on the 'Trade' tab).

 
Valmars:

The position is the same as it was, only the direction has changed. When a position is opened, the comment is rewritten, when a deposit is made, too. But when I reverse, it does not. The reason of the change is specified there. In the history of trades and orders, the comment is present. It is not the MQL5-program but the terminal itself. The field remains empty even for manual reversal with the comment specified.

I think it should be filled in from the order. Otherwise we cannot see who has changed the position, the Expert Advisor or manually (visually, in the 'Trade' tab).

If the direction is changed, the existing Out position is closed and the new In position is reopened.

If I remember correctly.

Example:

1. We have a Buy position of 0.10 and a Sell order (limit or stop order) with the lot 0.20 triggers.

As a result, the Buy position is closed and a new Sell position of 0.10 is created.

2. Suppose there was a Buy 0.10 position with the comment "New position" (the deal is supposed to be marked In), we average Buy 0.10 with the comment "Averaging Buy - XXXX" (the deal is supposed to be marked In).

The resulting position should be Buy 0.20 with the comment "Averaging Buy - XXXX".

Here we decide to reverse the position and go Sell 0.30 with the comment "Upheaval Sell - XXXX".

We should have a Sell 0.10 position with the comment "Upheaval Sell - XXXX".

It should be the closing of a Buy position + opening of a new Sell position.


The closing of Buy 0.20 position (Averaging Buy - XXXX) will be marked in the log as Sell 0.20 Out (comment should be clarified).

The opening of a new position will be marked in the log as Sell 0.10 In (Upheaval Sell - XXXX).

PS

I will check later how it looks like in the tester in reality.

 
Valmars:

It's not the MQL5 program, it's the terminal, because even with a manual reversal with a comment the field stays blank.

I think it should be filled in from the order. Otherwise it's not clear who changed the position; EA or manually (visually, on the 'Trade' tab).

Then it's up to the developers at Sevrvisdesk.
 
Valmars:

The position is the same as it was, only it has changed direction.

It is a question of terminology, nothing more. Therefore, it is advisable to look up the definition of position in the documentation.