Templates and Profiles
A template is a set of chart window parameters that can be applied to other charts. The following can be stored in a template:
•chart type and color;
•OHLC line shown or hidden;
•attached Expert Advisor and its parameters;
•imposed custom and technical indicators with their settings;
•separators of days.
When a template is imposed into a chart, the stored settings, as they are, will be attached to the security and period. For example, one can create a template that includes indicators of MACD, RSI, and Moving Average, and then use it for other charts. In this case, charts windows will have the same view for different symbols and periods.
Templates are stored in the /Profiles/Templates directory in TPL files. A template created once can be used unlimited amount of times.
There are several predefined names of templates in the client terminal:
•default.tpl — the basic template that is automatically applied when creating a new chart;
•tester.tpl — the template that is used for a chart where the testing results are displayed;
•debug.tpl — the template that is applied to a chart created when starting the debugging of a MQL5 program from MetaEditor.
To create a template with necessary parameters (or change an existing one), adjust a chart in a desired way and save the template under necessary name using the corresponding command.
Any template can be changed by saving the active chart window properties to it.
Manipulations with Templates
In order to open the menu of working with templates, one should execute the "Templates" command of the "Charts" menu, the chart context menu command of the same name or press the button of the "Standard" toolbar. The following actions with templates are available from this menu:
Profiles offer a convenient way of working with groups of charts. The following can be stored in profiles:
•charts that were open at the moment when the profile was saved
•location and size of these charts;
•templates that were applied to these charts.
When a profile is opened, each chart with its settings is placed exactly in the same location where it was before, at the profile saving. All changes in open chart windows are automatically saved in the current profile. The list of all chart windows of the current profile can be found in the "Window" menu. The name of the current profile is displayed in one of the status bar windows and checked in the profile managing menu. When the terminal is installed, the profile by default (DEFAULT) is created. Initially, four basic currency pairs are stored in it: "EUR/USD", "USD/CHF", "GBP/USD", and "USD/JPY". All profiles are stored in the /Profiles/Charts folder.
Profile management is gathered in the menu that can be called by the "Profiles" command of the "File" menu, clicking the button of the "Standard" toolbar, or clicking in the status line window with the current profile name. The following actions can be performed here:
A pre-defined profile can be assigned to a trade account in the client terminal. This profile must have a name that coincides with the number of the trade account. If there is a corresponding profile when switching to the given trade account, it will be opened automatically. If there is no pre-defined profile, the current profile will remain active.
MetaTrader 5 — a complex trading platform for providing brokerage services on the retail Forex market.
Copyright 2000-2014, MetaQuotes Software Corp.