Expert Advisior runs every 2 Minutes the Init-Funktion

 

Hi,

I am testing my Expert Advision on an Demo Account and realized (with a Print-Message), that the MetaTrader is running the init-Funktion every few minutes, why?

What can I do against that?!

Lot's of thanks!!

 
sunshineh:

Hi,

I am testing my Expert Advision on an Demo Account and realized (with a Print-Message), that the MetaTrader is running the init-Funktion every few minutes, why?

What can I do against that?!


Don't recompile the EA.

Don't change the timeframe.


Both force the EA to finalise and initialise. The former reloads the EA as well.

 
sunshineh:

Hi,

I am testing my Expert Advision on an Demo Account and realized (with a Print-Message), that the MetaTrader is running the init-Funktion every few minutes, why?

What can I do against that?!

Lot's of thanks!!

init() function can be called from within the start() function in order to do something but looks strange. what does the init() contain?