Change Timeframe and Close MetaTrader

To add comments, please log in or register
Martin Moreno
143
Martin Moreno  

Hi guys.

when we change timeframe or close metatrader paltform, OnDeinit() function is called. I need to code whether timeframe is changed or Meta Trader is closed. Is there any way to check and distinguish  this difference ?

Keith Watford
Moderator
20312
Keith Watford  
Documentation on MQL5: Constants, Enumerations and Structures / Named Constants / Uninitialization Reason Codes
Documentation on MQL5: Constants, Enumerations and Structures / Named Constants / Uninitialization Reason Codes
  • www.mql5.com
//| get text description                                             | //| Expert deinitialization function                                 |
Martin Moreno
143
Martin Moreno  
Keith Watford:

https://www.mql5.com/en/docs/constants/namedconstants/uninit

This is for MQL4 and MQL5

Thanks a lot

To add comments, please log in or register