Discussion of article ""New Bar" Event Handler" - page 7

 
Thank you, very helpful
 

Regarding the last chapter of the article.

When compiling the file onnewbar.mqh(1.12 KB) and onnewbar.mq5(0.8 KB) respectively, I get an error.

Please explain why it does not work.

In the article, in the line

#include "OnNewBar.mqh" // here is the secret to start the "new bar" event handler

it says about the secret of launching the handler. What is the secret? It turns out that we refer to a file in which the onNewBar() function is not defined.