Posted By: Grat
EXITRUN for TRADE - 05/24/21 15:13
If is a possible, enable use flag "EXITRUN" also for Trade mode.
if (is(INITRUN)) ... work
if (is(EXITRUN)) ...not work
thanks
Posted By: Petra
Re: EXITRUN for TRADE - 06/19/21 08:07
I think if one clicks "Stop", they want to really stop it, not start an exitrun.
Posted By: Zheka
Re: EXITRUN for TRADE - 06/19/21 13:06
+1
One normally uses EXITRUN for calculating/logging some stats (and for other housekeeping - like freeing memory), at first when Testing...and having to make this work separately for Trade just wastes time and adds code .
I guesstimate it takes more lines in Zorro's code to forbid EXITRUN in Trade mode then to allow.
Why make assumptions about what one wants when pressing "Stop" in a live session?
Ideally, the transition from Test to Trade should be as simple as possible.
Posted By: Zheka
Re: EXITRUN for TRADE - 06/26/21 08:07
So, "if (suspended==16) quit("zzz"); " will raise an "EXITRUN" flag in Live and allow code under EXITRUN to run, correct?
The manual says quit() will close open trades - which might not be desirable....Can it just follow the "Close open trades?" dialogue in Live instead of closing trades by default?
Posted By: Spirit
Re: EXITRUN for TRADE - 06/26/21 17:28
In live mode you are always asked if you really want to close them, and if not they stay open.