Martin Friedrich:
Hello everyone,
I need help for a small script to indicated of arrows. I've an indicator which generation my arrows and I don't know the buffer to detect this in a script for a alert message.
Unfortunately, I haven't found anything suitable in the forum.
Thank you for your support.
Martin
So you want to write a script that gives you an alert when your buffer shows an arrow... on the current bar or what? Why not make it an indicator?
It works as an indicator, but for this I still have to recognize that an arrow has just been generated and in which direction. And currently I don't know how to recognize that.
Martin Friedrich #:
It works as an indicator, but for this I still have to recognize that an arrow has just been generated and in which direction. And currently I don't know how to recognize that.
A DRAW_ARROW buffer contains 0.0 where there will be no arrows and some price where there will be arrows, then there is an Arrow shift so the arrows will not be plotted directly on the candles but slightly above/below. It works as an indicator, but for this I still have to recognize that an arrow has just been generated and in which direction. And currently I don't know how to recognize that.
Then there will be a line PlotIndexSetDouble(plot_index,EMPTY_VALUE,0.0) which replaces all the zeros in the buffer by the empty value number which is a very large number so you won't have the zeros plotted.
So basically you want all the bar indexes where the Arrow buffer is not zero and the prices in there.
I suggest you look at the code of MQL5/Indicators/Examples/Fractals, it has got to do with Arrows. There you can see the number of the buffer that stores the data that is used for arrows. You can save a copy of it and play around with that to see how it behaves on the chart. Then you look up the parts of the code in the documentation. That might give you an idea of what you are looking for.
![Indicator Buffers Indicator Buffers](https://c.mql5.com/36/53/indicator-buffers.jpg)
Indicator Buffers
- www.mql5.com
This EA will detect the buffers values of any indicator you want. Just type its name in the EA settings.
![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
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
Hello everyone,
I need help for a small script to indicated of arrows. I've an indicator which generation my arrows and I don't know the buffer to detect this in a script for a alert message.
Unfortunately, I haven't found anything suitable in the forum.
Thank you for your support.
Martin