Looking for a Close All Ea Script Please

 

Greetings,


Does anyone know where I can find a close all EA script ( open, closed ) orders. Sometimes i have a over 30-40 open orders running and I need a script to execute all Close on those open orders


Thank You!

 
magicgrider:

Greetings,


Does anyone know where I can find a close all EA script ( open, closed ) orders. Sometimes i have a over 30-40 open orders running and I need a script to execute all Close on those open orders


Thank You!



Close_all_Open_and _Pending_Orders
 
MaxFactor:
Close_all_Open_and _Pending_Orders

Beautiful script!

Doesn't need...

extern int ProfitTarget = 10; // Profit target in dollars
Thank you, Helmut
 
MaxFactor:
Close_all_Open_and _Pending_Orders



Thanks!

 
engcomp:

Beautiful script!

Doesn't need...

Thank you, Helmut



Just a question .... in the code it says


extern int ProfitTarget = 10; // Profit target in dollars


If i set this profittarget = 0 will it close all open and pending orders ... ( even orders that are negative balance) this is what im looking for .


thanks

 
magicgrider:



Just a question .... in the code it says


extern int ProfitTarget = 10; // Profit target in dollars


If i set this profittarget = 0 will it close all open and pending orders ... ( even orders that are negative balance) this is what im looking for .


thanks

Question : this script is great, but if you have several orders open, with my broker I have error messages sended back.

Would it be possible to modify this script with a "while" maybe, so it will run until ALL orders are really closed ?