Detect time frame change

Tj11 since: 24 Oct 2019; 
 13 Feb 2020, 21:44
Detect time frame change

Dear Support,

Is there a way for the indicator to immediately detect that the time frame was changed ? Without waiting for a new tick to come.

If there is non, what would you advise as a workaround ?  Double mouse click, button on the chart or ?

API reference is not clear.

Thanks in advance.

Tj11 since: 24 Oct 2019; 
 14 Feb 2020, 10:27

Dear Support, may I have your reply please.

Panagiotis Charalampous's avatar
Panagiotis Charalampous since: 13 Jan 2017; 
 17 Feb 2020, 08:59

Hi Tj11,

No there is no such option. When the timeframe changes, a new indicator is initialized and the Initialize() method is called.

Best Regards,

Panagiotis 

Join us on Telegram

Head of Community Management at cTrader
Tj11 since: 24 Oct 2019; 
 17 Feb 2020, 19:57
RE:

PanagiotisCharalampous said:

Hi Tj11,

No there is no such option. When the timeframe changes, a new indicator is initialized and the Initialize() method is called.

Best Regards,

Panagiotis 

Join us on Telegram

Hi Panagiotis,

If I got you right, changing the time frame will immediately execute the code inside Initialize() without waiting for a new tick, right ?

If yes, then this is exactly what I need. You saved my time. Thank you !

Regards