New to MQL4 and having troubles using Comment

 

I am very new to this language and grasp most of it but i am having trouble getting comments to output to my chart.

Here is my Code

void OnTick()
  {
   Comment("hello");


  }


Ive checked the background color and tried different terminals and they all produce no outcome using Comment.

 
FynnS:

I am very new to this language and grasp most of it but i am having trouble getting comments to output to my chart.

Here is my Code

void OnTick()
  {
   Comment("hello");


  }


Ive checked the background color and tried different terminals and they all produce no outcome using Comment.

It is the weekend. If there are no new ticks, OnTick() will not be called.

Try it in OnInit().

 
Keith Watford #:

It is the weekend. If there are no new ticks, OnTick() will not be called.

Try it in OnInit().

Thank you so much i have been messing with this for hours on end before moving forward with my learning.
 
FynnS:

I am very new to this language and grasp most of it but i am having trouble getting comments to output to my chart.

Here is my Code

void OnTick()
  {
   Comment("hello");


  }


Ive checked the background color and tried different terminals and they all produce no outcome using Comment.

You could also call OnTick() from OnInit()

Thats quite handy if you have a lot of code in your OnTick function but you're not getting ticks, on the weekend ;)

\

void OnInit(){
   OnTick();
  }

void OnTick(){
  Comment(TimeCurrent()," ","hello");
}