MetaTrader 4 Build 600 If I execute this script on a weekly graph. I get Weekly, without debug . And I get H1, with debug . Where is my mistake?

 
Hello,

MetaTrader 4 Build 600
If I execute this script on a weekly graph :

//+------------------------------------------------------------------+
//|                                                       Test01.mq4 |
//|                        Copyright 2014, MetaQuotes Software Corp. |
//|                                              https://www.mql5.com |
//+------------------------------------------------------------------+
#property copyright "Copyright 2014, MetaQuotes Software Corp."
#property link      "https://www.mql5.com"
#property version   "1.00"
#property strict
//+------------------------------------------------------------------+
//| Script program start function                                    |
//+------------------------------------------------------------------+
void OnStart()
  {
//---
   printf(ChartPeriod(ChartID()));

  }
//+------------------------------------------------------------------+

I get Weekly, without debug .
And I get H1, with debug .

Where is my mistake?

Regards,

Pierre

 
tintin92:
Hello,

MetaTrader 4 Build 600
If I execute this script on a weekly graph :

I get Weekly, without debug .
And I get H1, with debug .

Where is my mistake?

Regards,

Pierre

You have to set the timeframe for debug on Weekly. Menu Tools, Options, Debug tab.
 
Thanks angevoyageur.
Reason: