Count closed trades/completed trades; if (300) {closealltrades} need help
Yes, it is possible . . . but any EA can only see the Account History exposed to it . . if a user sets the Account History to only show the last month then that is all the EA will see.
Hi everyone, just wondering if it is possible to include in an EA the following.
I would like my EA to count closed/completed orders after every close/takeprofit/.
and if the closed orders value reaches a certain number, any number defined by user ie (300 completed orders)
then close all orders. this is not code i have no idea how to write this and could not find it anywhere
something along the lines of
================================================
Count number of TakeProfits (because this would indicate a closed order)
if (count=300)
{
Closeallorders;
}
================================================
any advice is appreciated.Thank you for reading my mess