There is a code on the real chart the comments are correct. in the strategy tester all values are equal to 2147483647
What is wrong here?
Or should we add EMPTY_VALUE to the check?
And should we always normalize obtained data from the indicators for comparing them to each other in 5 digits?
The indicator buffer has a concept of "empty value". It (by default) equals EMPTY_VALUE, but it can be changed using the SetIndexEmptyValue() function. This is the value the buffer does not draw in the chart (if it draws at all). It is the missing value that needs to be checked, if necessary.
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
There is one variable missing from the indicator call - the buffer!!!
It's working. Thanks again.
Question for connoisseurs.
There is a code on the real chart the comments are correct. in the strategy tester all values are equal to 2147483647
What is wrong here?
Or should we addEMPTY_VALUE to the check?
And should we always normalize obtained data from the indicators for comparing them to each other in 5 digits?
Question for connoisseurs.
There is a code on the real chart the comments are correct. in the strategy tester all values are equal to 2147483647
What is wrong here?
Or should we add EMPTY_VALUE to the check?
And should we always normalize obtained data from the indicators for comparing them to each other in 5 digits?
#property copyright "Copyright © 2012" #property link "Не ссать против ветра " extern bool Будильник = true ; extern string SoundFile = "News.wav"; int start () { double a=iCustom(NULL,0,"HMA_Russian_Color",5,MODE_LWMA,PRICE_MEDIAN,"Uptrend[]",0); double b=iCustom(NULL,0,"HMA_Russian_Color",8,MODE_LWMA,PRICE_MEDIAN,"Uptrend[]",0); if (Будильник ==true) { { if ( a > b ) { Alert("BUY PlaySound(SoundFile); Sleep(100000); } } } return(0);}mmm ...there's also a problem ...the beep sometimes sounds like it's set in the News.wav code and more often it rings Alert.wav
Could you please tell me where the error is?
Please help me, tell me how to implement EA code in two or three lines:
When a signal comes in (e.g. crossing of two MAs)
1.Expert Advisor determines the time of the signal (in hours, minutes), stores it;
2. counts down one minute.
Next, readiness to do something (e.g. open an order)Question for connoisseurs.
There is a code on the real chart the comments are correct. in the strategy tester all values are equal to 2147483647
What is wrong here?
Or should we add EMPTY_VALUE to the check?
And should we always normalize obtained data from the indicators for comparing them to each other in 5 digits?
Mm ... there's also a problem ... the beep sometimes sounds like the News.wav code and more often it rings Alert.wav
There's some nonsense written here:
Read about iCustom().
Please help me, tell me how to implement EA code in two or three lines:
When a signal comes in (e.g. crossing of two MAs)
1.Expert Advisor determines the time of the signal (in hours, minutes), stores it;
2.Countdown one minute.
Next, readiness to do some action (e.g. opening an order)In a global variable you write the time value at the moment of the signal receipt:
and then count down your minute (you can do this):
This is one solution to track the time after an event has occurred.
In a global variable, write the time value at the time of the signal:
and then count down your minute (you could do that):
This is one solution to tracking the time after some event has occurred.
Alternatively, you can set any time after the signal arrives