Indicator re-started NOT on every tick

Back to topics list To post a new topic, please log in or register
Webmeiker 2015.08.17 22:11


I have made my first indicator, but I don't want it to be started again and again at every tick.

Its a "slow" indicator suitable for the 4H period. So for me should be enough if it gets re-started only when a new candle opens, for example, or when the user refresesh the graphic window...

After reading the documentation I didnt find the solution. 

This approximation works for me, but I want to know if exists a better way:

extern bool FlagOnlyOneExecution = true;

int start() {          

if (FlagOnlyOneExecution) {

//... do the thing here ...


FlagOnlyOneExecution = false;

Could somebody give me advice?
WHRoeder 2015.08.18 14:01 #
Test for a new candle.
Back to topics list  

To add comments, please log in or register