Hi, can someone tell me the code so the simple example indicator I attach only issues an alert after the close of the candle if the signal stays valid and not keep alerting during the duration of the candle???
The idea is to find out if there is a new bar. we can doing that by comparing the current bar time with a time that we save.
here is the code for this routine
static datetime dt = 0;
if (Time != dt)
dt = Time;
Now before we check our condition we can check if the bar has changed. Something like that
i=Bars-counted_bars; // your original line of code
if (!NewBar()) // Check if new bar occurs
while(i>=0) // your original line of code
thanks a lot for the code!!!!!
Is it possible to alert when closed price >= X value
Let say on 1 hour chart,
Is it possible to do a alert when closed price >= X value .
Is there any existing indicator that do such function?
Would you mind post the new .mq4 with the modified code?
*sorry, i am still learning *
I moved your post to this thread - some indicator was posted and may be it is what you are looking for.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.