Download MetaTrader 5

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?

To add comments, please log in or register
Pierre Rougier
390
Pierre Rougier  
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

Alain Verleyen
Moderator
32498
Alain Verleyen  
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.
Pierre Rougier
390
Pierre Rougier  
Thanks angevoyageur.
To add comments, please log in or register