Custom symbols. Errors, bugs, questions, suggestions. - page 16

 
Roman:

But have in mind that the sign of explicitness is broken.

Read the documentation carefully. It's all clearly written there.

And articles about automated trading.

 
Roman:

And that's it.

Sets All, which corresponds to all allowed.

And in the documentation there is nothing in the "Value" column, it is empty!
And in the "Identifier" column for the "Return" line, I still suggest specifying the correct combination for the flags!
Why not just addSYMBOL_FILLING_RETURN with value 3, clearly and understandable to everyone.

Why 3? You clearly don't understand the difference between enumeration constants and flags. Read the values of the other flags, e.g. - flags of allowed order types:

Документация по MQL5: Константы, перечисления и структуры / Состояние окружения / Информация об инструменте
Документация по MQL5: Константы, перечисления и структуры / Состояние окружения / Информация об инструменте
  • www.mql5.com
Для получения текущей рыночной информации служат функции SymbolInfoInteger(), SymbolInfoDouble() и SymbolInfoString(). В качестве второго параметра этих функций допустимо передавать один из идентификаторов из перечислений ENUM_SYMBOL_INFO_INTEGER, ENUM_SYMBOL_INFO_DOUBLE и ENUM_SYMBOL_INFO_STRING соответственно. Некоторые символы (как...
 
Artyom Trishkin:

Why 3? You clearly do not understand the difference between enumeration constants and flags. Read the meanings of the other flags, e.g. - flags of allowed order types:

Artyom, his lack of understanding was evident in the first post on the previous page, #141. And for so long you have been talking in different languages.
 
Artyom Trishkin:

Why 3? You clearly do not understand the difference between enumeration constants and flags. Read the values of other flags, e.g. - flags of allowed order types:

Artem, we're talking about setting custom character properties, flags for order type have nothing to do with it.
3 because the combination SYMBOL_FILLING_FOK | SYMBOL_FILLING_IOC returns 3
and if we add a new SYMBOL_FILLING_RETURN identifier, it will return 3.

And your explanation above also says so, only you must have made a mistake, instead of "or" I wrote "and".
I'm quoting you as well:

  • If there is a SYMBOL_FILLING_FOK flag, and there is a SYMBOL_FILLING_IOC flag, then SYMBOL_FILLING_MODE will return 3. At the same time there is a "Return".

 
Roman:

Artem, we are talking about setting custom character properties, flags for order type has nothing to do with it.
3 because the combination SYMBOL_FILLING_FOK | SYMBOL_FILLING_IOC returns 3
and if we add a new SYMBOL_FILLING_RETURN identifier, it will return 3.

And your explanation above also says so, only you must have made a mistake, instead of "or" I wrote "and".
I'm quoting you as well:

  • If SYMBOL_FILLING_FOK flag is present and SYMBOL_FILLING_IOC flag is present, SYMBOL_FILLING_MODE will return 3. At the same time there is a "Return".

Roman, you really don't understand what a set of flags is. How much would 1 and 2 add up to? That's probably something you can solve without mistakes. That's why it is And.

 
Alexey Viktorov:

Roman, you really don't understand what a set of flags is. What is the sum of 1 and 2? That's probably something you can solve without mistakes. That's why it's AND.

Check what the AND returns.

CustomSymbolSetInteger(SName, SYMBOL_FILLING_MODE, SYMBOL_FILLING_FOK & SYMBOL_FILLING_IOC);

And then this

CustomSymbolSetInteger(SName, SYMBOL_FILLING_MODE, SYMBOL_FILLING_FOK | SYMBOL_FILLING_IOC);
And then this
CustomSymbolSetInteger(SName, SYMBOL_FILLING_MODE, 3);
 
Roman:

Check what comes back AND

And then this.

Print this code

Print("summ_flags = ", SYMBOL_FILLING_FOK | SYMBOL_FILLING_IOC);

This is how you set permissions for SYMBOL_FILLING_FOK and SYMBOL_FILLING_IOC flags

Repeat the experiment with these values

Print("summa_flag = ", 1 | 2);

Then with this

Print("summa_flag = ", 1 | 2 | 3);

And with these

Print("summa_flag = ", 1 | 2 | 4);
 
Alexey Viktorov:

Print out this code.

This is how you set permissions for the SYMBOL_FILLING_FOK and SYMBOL_FILLING_IOC flags.

That's a tough one, guys.

SYMBOL_FILLING_FOK | SYMBOL_FILLING_IOC

Which operator do you think it is |?? Operator AND?

 
Roman:

That's rough, guys.

What kind of operator do you think this is ??? E operator ???

No! It's an OR operator !!! But it sets the permissibility to choose either SYMBOL_FILLING_FOK or SYMBOL_FILLING_IOC so there should be an AMOUNT of the values of those flags. And the sum is exactly AND. 1 and 2 will add up to 3.

zy. It is the lack of understanding of this that indicates a lack of understanding of flags in general.
 
Alexey Viktorov:

No! This is an OR operator!!! But it sets the permissibility of either SYMBOL_FILLING_FOK or SYMBOL_FILLING_IOC so there must be an AMOUNT of these flag values.


You are contradicting yourself. In one message you write AND. Now you write OR.
You clearly have a definition problem. We are writing high-level mql language, not bits.
The fact that bits will have AND as a result of addition is clear, but we don't see it, but we know about it.
To put it more logically, so that you can be understood by others, Bitwise OR returns the sum of flag values!
But not AND !
Let's close this subject.

Reason: