Download MetaTrader 5

How to find out the active chart window?

To add comments, please log in or register
mar
1146
mar  

Hi coders,

if I have opened 20 charts I only want some calculations done on the chart I am currently watching. So it might be useful for an indicator to check if a chart is currently active. I found a solution here:

https://forum.mql4.com/30084#276651

but this posting is from 2010 and I wanted to ask if the new MQL4 offers a better way to do that. I see that CHART_WINDOW_HANDLE wasn't available in 2010. So my question is do I still need some Windows-functions or can it be done by MQL4 only?

Thanks! 

Alain Verleyen
Moderator
31614
Alain Verleyen  
mar:

Hi coders,

if I have opened 20 charts I only want some calculations done on the chart I am currently watching. So it might be useful for an indicator to check if a chart is currently active. I found a solution here:

https://forum.mql4.com/30084#276651

but this posting is from 2010 and I wanted to ask if the new MQL4 offers a better way to do that. I see that CHART_WINDOW_HANDLE wasn't available in 2010. So my question is do I still need some Windows-functions or can it be done by MQL4 only?

Thanks! 

It's unchanged, I don't think there is an other way.
mar
1146
mar  
Ok, thanks!
To add comments, please log in or register