Any questions from newcomers on MQL4 and MQL5, help and discussion on algorithms and codes - page 391

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
Guys, could you please advise how to convert the date 29.01.2008 to a format like 1201564800 ? What function is used to do this?
I need to compare TimeCurrent () with a given historical date...
Is that ok?
Guys, could you tell me how to convert the date 29.01.2008 to a format like 1201564800 ? What function is used to do this?
I need to compare TimeCurrent () with a given historical date...
If you convert the current time to a second format via iTime: int iTime = TimeCurrent();
then how can it be compared to other dates which are written in the 29.01.2008 format?
Or somehow compare it without converting it to seconds, if you can do it straight away...
like
if TimeCurrent() > 29.01.2008 then a = 123456
but it doesn't work in this form... ((
datetime is a long
So, to represent a datetime as a long, you need to explicitly convert:
Hello.
Question onstrategy tester
I can't reduce the font or column sizes to fit the entries within the 640 pixels window
how do I do this?
I have reduced the window size, but the information is crumpled.
Hello.
Question onstrategy tester
I can't reduce the font or column sizes to fit the entries within the 640 pixels window
how do I do this?
I have reduced the window size, but the information is crumpled.
Afternoon!
Please give me a hint, there is a piece of code:
I am looking for breakdowns from the price channel, my task is to check if the breakthrough is not by any candlestick, but by a pinbar and open an order after the pinbar is formed.
Please, advise me how to do it. I am struggling with this for the third day but so far I have not seen any solution.
To check if the breakthrough occurred not by any candle but by a pinbar and to open an order after the formation of the pinbar. Please tell me how to implement this, I am struggling for three days and do not see a solution yet
I am currently debugging an Expert Advisor that works well in the Strategy Tester within a month. And it is good on the demo. I got distracted and looked here. Do you have the drawing?
Now I am debugging the Expert Advisor that I have been testering for a month. And it is good on the demo. I got distracted and looked here. Do you have the drawing?
Like this, for example. The yellow line is the price channel that the price should break through, and the order would open with a smiley, and all the ones that were there before would be ignored.
Like this, for example. The yellow line is the price channel that price has to break through, and that the order would open with a smiley face candle, and ignore all the ones before that
It won't work.
Reply
Artyom, you didn't read it carefully: the TS needs to open only at a pin bar breakout, respectively if you prescribe a pin bar (small body and large shadows), the condition can be met
How is the iCustom function handled in MT4? Please reply to those who know about it!
For example, in the strategy tester an Expert Advisor calls the indicator at every tick.
When the function is called, the indicator is loaded into the memory, recalculates all values from zero bar to Bars and then returns the value at the required offset.
If I request the value of 1 bar on the first tick and the value of the second bar on the second tick, then my Expert Advisor will calculate the indicator twice on the entire history?
If the Expert Advisor accesses the indicator1, and it has iCustom to the indicator2. How many times will the indicator2 be recalculated when requesting the value of indicator1?
Maybe the Strategy Tester and the MT4 terminal stores the indicator values on every bar, so they won't recalculate them at the repeated request?