Here we go. Finally!!! I’ve been trying to get this done for weeks
This is a massive step forward, now I can stop looking at a chart all existing minutes of the day and focus on actually studying MQL from the basics up, the correct way.
Thanks again, such a small little tweak, with a massive result.
extern double AddPipp = 1000;
//extern double Add5Pipps = 500;
extern double SubtractPipp = 1000;
double Asktarget = 27760;
//double Asktarget9 = 27769;
double Bidtarget = 27740;
if(Ask > Asktarget) //remember, ask is the higher one.
Alert("Dow Ask is Higher ",Ask);
SendNotification("Dow Ask is Higher " + Ask);
Asktarget = Asktarget + AddPippPoint;
Bidtarget = Bidtarget + AddPippPoint;
if(Ask > Asktarget9)
Bidtarget = Bidtarget + Add5Pipps*Point;
Far too much code needed, and potential errors, to do it this way for now.
Better to start the entire program with an isfirsttick statement,
and when it is the first tick, change the values of The initial Ask and Bid targets, to
reflect a space where there will be a target of 10 points between the two.
It can be done, by making the Ask target, be 1 point below the Ask price.
If Offset erros happen later on, just reset the program. This is a temporary fix.
if(Bid < Bidtarget)
Alert("Dow Bid is Lower ", + Bid);
SendNotification("Dow Bid is Lower " + Bid); //Bid is the Lower one
Bidtarget = Bidtarget - SubtractPippPoint;
Asktarget = Asktarget - SubtractPippPoint;
//Some minor offset errors, with no immediate need to fix:
//If Ask is hit at about 21 points higher, it will raise the new Ask level by 30 points,
//while it will also raise the Bid by 30 points. If the initial prices are set intervals
//of 20 apart, then the Bid price will only have to travel about 7 points to reach the Bid alert.
//If however, the level that the Ask price hits, is about 27 points above, this will do the same
//as the above comment in the beginning, but now, the bid price will need to travel about 13 points
//to hit the Bid alert, while also making the new alert target for the Ask price, to be only 3