![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
The AccountInfoInteger( ACCOUNT_LOGIN ) function will get the new login account number before the EA be called by OnDeinit() event when the user switch to another account with the same broker. (Not sure if it will be so when switching to other brokers' accounts)
It supposed to be the logout account number before the end of OnDeinit() event, right? But it now not works like that, seems EA will get the new account number is login even in the event OnDeinit() of the logout account, and before the OnInit() event of the new login account, so EA could be having some trouble when it is still processing the data of the logout account.