How avoid Indicator reset when changing timeFrames

 

Hi everyone.

I got in this comunity a Risk to reward ratio indicator for mt4 , I have made modifications and so far so good, the only thing bothering me right now is

that when place TP and SL lines for calculations , every time I switch timefrime, those lines go back to the default position as when the indicator is loaded.

How can I avoid this? so the lines can be locked in that place no maatter which timeframe I switch to.


Thanks 

 
totetronico:

Hi everyone.

I got in this comunity a Risk to reward ratio indicator for mt4 , I have made modifications and so far so good, the only thing bothering me right now is

that when place TP and SL lines for calculations , every time I switch timefrime, those lines go back to the default position as when the indicator is loaded.

How can I avoid this? so the lines can be locked in that place no maatter which timeframe I switch to.


Thanks 

Provide the user the ability to input the time frame used for calculations, instead of using the chart time frame.

extern int calc_time = 15; //time frame for calculations

This way all calculations are done using the input time frame and not the chart time.

- Jack

Reason: