metatrader4 - MQL4 How To Detect Status During Change of Account (Completed Downloading of Historical Trades) -
metatrader4 - MQL4 How To Detect Status During Change of Account (Completed Downloading of Historical Trades) -
in mt4, there exists stage/state: when switch accounta accountb, when connection established , init() , start() triggered mt4; before "blinnnggg" (sound) when historical/outstanding trades loaded server.
switch account>establish connection>trigger init()/start() events>start downloading of outstanding/historical trades>completed downloading (issue "bliinng" sound).
i need know (in mql4) trades completed downloaded tradeserver --to know business relationship empty -vs- still downloading history tradeserver.
any pointer appreciated. i've explored istradeallowed()
iscontextbusy()
, isconnected()
. these in "normal" state , init() , start() events fired ok. cannot figure out if history/outstanding trade lists has completed downloading.
update: final workaround implemented utilize ordershistorytotal()
. apparently number 0 (0) during downloading of order history. , never 0 (due initial deposit). so, ended-up using "flag".
metatrader4 mql4
Comments
Post a Comment