Hello
Why is this not working if I might ask:
The EA works when I've just the profit side of things but once I add the loss side as well it opens and closes the orders immediately after launching the pending orders which it places.I just want the EA to close all order when a particular profit or loss level is attained....
(Please bear in mind I just started coding about a month ago.Also how do I add code in that funny window here atforexintuitiveand not at the primary article )
In the International area I announce:
double initaite_equity=0;
From the init I announce:
initaite_equity=AccountEquity();
Then in the OnTick:
if(Enable_Total_Profit==true)
if(AccountEquity()-initaite_equitygt;=Total_Profit)
Print(The Desired_Profit attained as complete profit is at: Total_Profit);
CloseAll();
if(Enable_Total_Profit==true)
if (initaite_equity)-(AccountEquity()gt;=Total_Loss);
Print(Max reduction reaced at: Total_Loss);
CloseAll();
Thanks for your time