Download MetaTrader 5

Delete pre-alert - page 2

To add comments, please log in or register
Keith Watford
Moderator
9642
Keith Watford 2016.03.20 07:59  

As I have banned eevviill for a week, he will not be replying to you soon.

      if(iDeMarker(NULL, PERIOD_CURRENT, 4, i) == 0 //DeMarker is equal to fixed value
      && iDeMarker(NULL, PERIOD_CURRENT, 4, 1+i) != 0 //DeMarker is not equal to fixed value
      )
        {
         Buffer3[i] = Low[i] - iATR(NULL, PERIOD_CURRENT, 14, i); //Set indicator value at Candlestick Low - Average True Range
         //Buffer1[i]=False;
         //Buffer2[i]=False;
         ArrayInitialize(Buffer1, 0);
         ArrayInitialize(Buffer2, 0);
        }
      else
        {
         Buffer3[i] = 0;
        }

Should delete all the pre-alert dots, obviously do the same for Buffer4

From your image, it appears that the pre-alerts always appear 1 bar before the confirmed alerts. If this is true, you could use

         Buffer1[i+1]=0;
         Buffer2[i+1]=0;

Instead, this would, I believe, leave any pre-alerts that are not confirmed on the chart

Massimo
479
Massimo 2016.03.20 08:16  
GumRai Hello, Your code works, but I wish when the red or green arrow all the yellow dots were deleted, even those unconfirmed.
Greetings, and thanks for your patience, Massimo.
Keith Watford
Moderator
9642
Keith Watford 2016.03.20 10:06  
omissamf:
GumRai Hello, Your code works, but I wish when the red or green arrow all the yellow dots were deleted, even those unconfirmed.
Greetings, and thanks for your patience, Massimo.

Doesn't

         ArrayInitialize(Buffer1, 0);
         ArrayInitialize(Buffer2, 0);

remove all the dots?

Massimo
479
Massimo 2016.03.20 10:58  
Hello GumRai, Your code works fine !!!You are a great !!!! Excuse me but I had not seen your previous post, because I had read it from the phone.Thanks for everything, greetings, Massimo.
12
To add comments, please log in or register