UninitializeReason()
-
Hello @fxDreema
I would like to request if you could be so kind to check the OnDeinit section of the compiled code.
I realize that some expert advisors were removed from the chart where they were running on my broker´s demo account without apparently reason. I looked a the Journal tab and I saw some logs about the EAs removal
But nothing about the reason why they were removed.
I was looking to implement a way to log the reason for the EAs removal and I found this function
https://docs.mql4.com/constants/namedconstants/uninit
So, I wanted to implement that function to my EAs code but I saw that you have already added it to the compiled projects.

I would say that might be there is a bug because when I removed an EA from its chart, I did not see any log about the reason why it was removed.

Thanks to a suggestion from @miro1360,
https://ctrlv.cz/shots/2019/07/19/Wmr9.png
When an EA is removed from the chart, the terminal sends me an email with the reason code which is very useful as well.

But, please, could you take a look at that part of the code to check if there was a bug for that function?
Thanks