[ARCHIVE]Any rookie question, so as not to clutter up the forum. Professionals, don't pass it by. Can't go anywhere without you - 5. - page 14

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
I tried everything, if I put value of 20 bar in green buffer then red is drawn further, if I assign EMPTY_VALUE to red buffer 20, then red to 20 is not drawn. Please show me an example, I would be very grateful to you
P.S. And learn to insert code into your posts - through button "SRC" (in the text entry field menu). Here about it more in detail.
Variables or arrays of variables are used for this purpose. In fact, MySQL is also an array of variables and a set of rules that allow you to work with this array.
Can you please give an example?
Buffers should be filled by some condition, for example by bar number (from the 20th to the 40th bar we draw in green):
P.S. And learn how to insert code into your posts - via the "SRC" button (in the text entry field menu). Read more about it here.
Yes, my bad, sorry.
Thanks for code. I will look into it.
What kind of men you are, you can't help a poor girl, all I ask is such a trifle.
Here's a link to coloured MA, for example.https://www.mql5.com/ru/code/9145
I just need an example, but simpler and clearer with one coloured line on tops or bottoms of bars, without calculation algorithms.
Please respond to my request. Thank you in advance.
Can I ask you a couple more questions?
My indicator has two lines, which I drag with my mouse across the screen, like the Alert function in the terminal, but more convenient. But it goes crazy when switching to a monthly chart. It is of course not that important, but I would like to know the reason.
The second question. Does mql4 have limitations in creation of objects using the ObjectCreate function?For the line to be drawn in different colours (it is assembled from separate "pieces" of lines of different colours), you need to activate as many buffers as you want in the colours of the line being drawn.
In your example, on the 20th bar the values must be put in the buffer that draws the green line, and all other buffers on that bar must have an empty value that is not drawn on the chart. The default value is EMPTY_VALUE.
P.S. The coloured MA link you provided is elementary and very clear about what I wrote to you above.
In general, it is elementary and understandable, but it is beyond the scope of standard tools for building indicators, and a person who only develops standard tools is not elementary and understandable. I actually meant that the standard function at one time can draw only one segment from the data from one buffer, and to draw the next one, you should remember the previous one, and then assemble them together.... This is all possible, and in various ways, but for someone asking these kinds of questions they won't all be straightforward.
Can I ask you a couple more questions?
My indicator has two lines, which I drag with my mouse across the screen, like the Alert function in the terminal, but more convenient. But it goes crazy when switching to a monthly chart. It is of course not that important, but I would like to know the reason.
The second question. Does mql4 have limitations in creation of objects using the ObjectCreate function?What does it mean to go crazy?
What do you mean, is it going off the rails?
But it is beyond the scope of standard tools for building indicators, and for a person who is just learning the standard tools is elementary and understandable.
Can I ask you a couple more questions?
My indicator has two lines, which I drag with my mouse across the screen, like the Alert function in the terminal, but more convenient. But it goes crazy when switching to a monthly chart. It is of course not that important, but I would like to know the reason.
The second question. Does mql4 have limitations in creation of objects using the function ObjectCreate?