Problem with creating variable using CHART_SCALE in MQL4.

 
Hello everyone!

I need help here.

I am creating a custom indicator for mt4 platform. This will create a text index on the graph screen. So far so good.

My problem is that I want to create a variable using the current value of CHART_SCALE. When you change the zoom on the mt4 screen, the text changes position.

In the end, I want a variable that has the current value of the zoom the screen so I can put this variable in the function I have created.

Thanks for listening!
I await response.
 
   long scale=ChartGetInteger(0,CHART_SCALE);

'scale' will be a value from 0 to 5

Reason: