Download MetaTrader 5
To add comments, please log in or register
Find out how your rating can be improved
Automated-Trading
Admin
94236
Automated-Trading 2014.07.30 13:01 

Quickly Open Charts with Different Timeframes:

Easy script to help analyze specified symbol, it opens 8 new charts with different periods and applies a specified template.

Author: Tadeusz Kiesner

Jeremy Roach
2421
Jeremy Roach 2014.11.07 07:54  
Hey,

Thanks for this.

Do you know how I can modify the code to open up multiple symbols on multiple time frames?

I wasn't sure how to add the symbols that I wanted to open into your code.

Any help would be great.


Thanks 
Quickly Open Charts with Different Timeframes
Quickly Open Charts with Different Timeframes
  • votes: 4
  • 2014.07.30
  • Tadeusz Kiesner
  • www.mql5.com
Easy script to help analyze specified symbol, it opens 8 new charts with different periods and applies a specified template.
Siti Latifah
6212
Siti Latifah 2016.01.26 01:23  

hello,


I just made a little modify.

You can type pair as you want in the input setting.

//+------------------------------------------------------------------+
//|                                                         open.mq4 |
//|                                                               tk |
//|                                              http://www.mql5.com |
//+------------------------------------------------------------------+
#property copyright "tk"
#property link      "http://www.mql5.com"
#property version   "1.00"
#property strict

#property show_confirm
#property show_inputs

input string iSymbol="EURUSD"; //type pair symbol s you want.

string template_ = "np";
string theSymbol;
//+------------------------------------------------------------------+
//| Script program start function                                    |
//+------------------------------------------------------------------+
void OnStart()
  {
//---
  long nr;
  if (iSymbol=="") theSymbol=Symbol(); else theSymbol=iSymbol;
  nr = ChartOpen(theSymbol,1);
  ChartApplyTemplate(nr,template_);
  nr = ChartOpen(theSymbol,5);
  ChartApplyTemplate(nr,template_);
  nr = ChartOpen(theSymbol,15);
  ChartApplyTemplate(nr,template_);
  nr = ChartOpen(theSymbol,30);
  ChartApplyTemplate(nr,template_);
  nr = ChartOpen(theSymbol,60);
  ChartApplyTemplate(nr,template_);
  nr = ChartOpen(theSymbol,240);
  ChartApplyTemplate(nr,template_);
  nr = ChartOpen(theSymbol,1440);
  ChartApplyTemplate(nr,template_);
  //nr = ChartOpen(theSymbol,1440);
  //ChartApplyTemplate(nr,template_);
  nr = ChartOpen(theSymbol,10080);
  ChartApplyTemplate(nr,template_);
  //Print("vvvvvvvvvvvvvvvv"+ChartID());
  }
//+------------------------------------------------------------------+
/
To add comments, please log in or register