Force Refresh?

 

Hi

I have an indicator that works well apart from one problem. I have to change the time frame of the chart to force it to refresh and repaint the dots. My question then is is there a line of code I can add to the indicator that will force it to automatically refresh at the start of a new bar/candle?

Thanks in advance...

Lux

 

I second this...

luxinterior:
Hi

I have an indicator that works well apart from one problem. I have to change the time frame of the chart to force it to refresh and repaint the dots. My question then is is there a line of code I can add to the indicator that will force it to automatically refresh at the start of a new bar/candle?

Thanks in advance...

Lux

It would be nice to have this information...

Jason

 

Hi. It's not as simple as adding a line - the indicator is not dealing with new bars correctly. When you chage the TF you are indirectly refreshing all bars which is not the way to go, you just need the newest bar refreshed. What indicator is it?

luxinterior:
Hi

I have an indicator that works well apart from one problem. I have to change the time frame of the chart to force it to refresh and repaint the dots. My question then is is there a line of code I can add to the indicator that will force it to automatically refresh at the start of a new bar/candle?

Thanks in advance...

Lux
 
omelette:
Hi. It's not as simple as adding a line - the indicator is not dealing with new bars correctly. When you chage the TF you are indirectly refreshing all bars which is not the way to go, you just need the newest bar refreshed. What indicator is it?

It's the SHI signal. Works really well on 1HR chart in my limited tests but the refreshing every hour is a pain...

Lux

Files:
 

This should do the trick. Enjoy.

 

Thanks omelet...

I've loaded your version and will give it a test when the markets open again...

I'll update this thread after that.

Lux

Reason: