Questions from Beginners MQL5 MT5 MetaTrader 5 - page 265
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
What do you mean by 'align'? Normalize the mantissa by the number of decimal places? - That's what the NormalizeDouble function is for. If something else, describe it in more detail.
At input any positive double, at output rounded to the real price that can be at this instrument.
If the price step is 0.25, then round to 0.25. Sort of like this:
But that said, if there is an offset (like 0.13; 0.38; 0.63; 0.88), then it counts. Then:
on input 1.0 on output 1.13;
1.25 as input and 1.38 as output;
1,5 ---> 1,63...
At the API level, this could be coded into a couple of assembly language commands and it's clearly a basic function. I thought there was one =/
how to make an update to the new build via Live update. Where is this Live update
Thanks for the reply, I trade live and MT5 is always on. If the program itself prompts me to update, it's good, but if not, where is this Live update?
Good day to you all! There is a problem - I can't use the readings of another custom indicator in a custom indicator. I am almost sure I am doing it wrong but I will paste the code anyway:
In this code, the buffer of the Rate Of Changes indicator(aRocRatesEURUSD) is not available. I don't understand how to connect this indicator correctly, please help me to understand it.
Good day to you all! There is a problem - I can't use the readings of another custom indicator in a custom indicator. I am almost sure I am doing it wrong but I will paste the code anyway:
In this code, the buffer of the Rate Of Changes indicator(aRocRatesEURUSD) is not available. I cannot understand how to connect this indicator correctly, please help me to understand it.
Indicator handles must be declared in OnInit():
Otherwise, it turns out that you create a new custom indicator each time you call OnCalculate().Indicator handles should be declared in OnInit():
This does not work either. As a result, the array with the buffer is either empty or full of left values.
rates_total, // размер входных таймсерий
to the buffer
? This can really slow down the terminal. And besides, this is a very deep story.
I think you will find it interesting to read the articleThe Principles of Economical Recalculation of Indicators
And also read the help on the OnCalculate() function.
OK, even in the simplest case it doesn't work:
I don't understand where my mistake is. Copying the same indicator buffer in EA and script works, but not in indicator. The indicator handle is initialised without error.