How to set the color of a moving average? - page 2

 

The best approach for me was to set up the chart as I want it to look like (with all indicators, etc.) on Metatrader itself, then save a template (Charts -> Template -> Save Template) named "tester.tpl". When I open Tester (View -> Strategy Tester), it has the right appearance and shows the indicators as expected (Moving Averages, candle colors, etc.).

If you want the tester to look differently for different EAs, you should probably do as @Rodolpho Nogueira De Sousa said i.e. save the template with the exact same name as the EA. Example: EA name is "my_test" -> Template name should be "my_test.tpl".

From the docs at https://www.metatrader5.com/en/terminal/help/charts_advanced/templates_profiles:

  • default.tpl — the basic template that us automatically applied when you create a new chart;
  • tester.tpl — the template of the chart on which testing results are displayed;
  • debug.tpl — the template of the chart created when you start MQL5 application debugging from MetaEditor.
Hope that helps...
Templates and Profiles - Additional Features - MetaTrader 5 Help
Templates and Profiles - Additional Features - MetaTrader 5 Help
  • www.metatrader5.com
When you apply a template to a chart, settings stored in it are applied to the instrument and timeframe. For example, you can create a template that includes indicators MACD, RSI, and Moving Average, and then use it for other charts. In this case, the chart windows look the same for different symbols and periods. To create a template with the...
 
Rodolpho Nogueira De Sousa:

Guys, 

I know this is an old thread, but if you save a .tpl file with the same name as the EA, you can change the appearance of lines for example.

 awesome thanks :)
Reason: