Questions from Beginners MQL5 MT5 MetaTrader 5 - page 1373
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
The buffer should not be caught by the colour, but by the value.
Look at what the buffer outputs when it changes colour.
I.e. let's say there are two buffers. Red and green.
Output these two buffers via Commen and trace what the buffer shows when it is 'active'. These are numerical values. These are the ones you interact with.
Don't give advice that is suitable for mql4 and not always suitable for mql5
Hello. How do I get the colour index in the Expert Advisor? (To get a signal when a colour changes).
As a rule, an indicator has a value buffer first, followed by a colour buffer.
Then you copy the values of the 1st or 3rd buffer after receiving the indicator handle. There can be only integer values from zero, 0 and above, depending on the number of colours defined in the indicator. All you need to know when programming the EA.
Can you tell me how to create a graphical object in MQL5 to avoid error 4202?
I used this code in MQL4:
But in MQL5 ObjectFind() returns error 4202
Can you tell me how to create a graphical object in MQL5 to avoid error 4202?
I used this code in MQL4:
But in MQL5, ObjectFind() returns error 4202
If no object is found, it is an object search error...
ERR_OBJECT_NOT_FOUND
4202
Graphical object not found
Don't alerts it...
If no object is found, this is the object search error...
ERR_OBJECT_NOT_FOUND
4202
Graphic object not found
You don't have to alert it...
Well, I was once taught that _LastError shouldn't return any errors at all. And it even seemed to be a requirement of the marketplace. Is it not so strict anymore?
And also, as far as I understand, this error could overwrite, some other more important error in the code, how to deal with that?
Well, I was once taught that _LastError should not return any errors at all. And it even seemed to be a requirement of the marketplace. Is it not so strict anymore?
And also, as far as I understand, this error could overwrite, some other more important error in the code, how to deal with it?
Somebody taught you badly. The _LastError variable will store the obtained value until the next, next error occurs.
It is a requirement of the marketplace that no execution errors are received from the broker server\dc. Read documentation...
Alexei, thank you for wanting to help. You, too, have the principle: to the hungry a rod, not a fish.