Change Template on All Charts
- Utilitaires
- Sahil Shokeen
- Version: 1.0
RavexAlgo — Change Template on All Charts [MT5]
Apply Any Template to All Open Charts in One Click
By RavexAlgo | www.ravexalgo.com | Platform: MetaTrader 5 (MT5)
Overview
The RavexAlgo Change Template Script for MetaTrader 5 (MT5) is a professional-grade utility script that allows traders to instantly apply any saved chart template across all open charts simultaneously — with a single click. No more manually switching templates chart by chart. Save time, maintain visual consistency, and streamline your trading workspace effortlessly.
Whether you use 10 charts or 50 charts, this script handles all of them in one execution — making it an essential tool for multi-symbol traders, prop firm traders, and anyone who values an organized trading environment.
⚡ Key Features
• Apply Template to All Charts at Once — Loops through every open chart and applies your chosen template automatically.
• Current Chart Only Mode — Option to apply the template to the active chart only, without affecting others.
• Custom Template Name Input — Simply type the name of any .tpl file saved in your MQL5 Templates folder.
• Detailed Summary Report — After execution, a popup displays total charts processed, successful applications, and any failures — with exact chart names.
• Automatic Chart Redraw — Each chart is redrawn immediately after the template is applied, ensuring instant visual update.
• Journal Logging — Full execution log is printed to the Experts/Journal tab for record-keeping.
• Input Validation — Prevents errors by detecting empty template names before the script runs.
• Zero Dependencies — No external libraries, DLLs, or additional files required.
⚙️ Input Parameters
| Parameter | Default | Description |
| Template Name | Default | Name of the .tpl file to apply (without extension) |
| Apply to Current Chart Only | false | If true, only the currently active chart is affected |
| Show Summary Report | true | If true, a popup report is shown after execution |
How to Use
Step 1 — Install the Script
• Open MetaTrader 5 (MT5) and go to File → Open Data Folder
• Navigate to MQL5 → Scripts and paste the script file there.
• Restart the terminal or right-click Navigator → Scripts and select Refresh
Step 2 — Prepare Your Template
• Save your desired chart template by right-clicking any chart → Template → Save Template
• Note the exact template name. The file will be saved in: MQL5 Data Folder → MQL5 → Profiles → Templates
Step 3 — Run the Script
• Drag the script from Navigator → Scripts onto any open chart.
• In the Inputs dialog, enter the Template Name (without the .tpl extension).
• Set Apply to Current Chart Only to true if you want to affect only one chart, or keep it false to apply to all charts.
• Click OK to execute.
Step 4 — Review the Report
• A Summary Popup will appear showing how many charts were updated successfully and which ones (if any) failed.
• Full details are also logged in the Experts / Journal tab.
⚠️ Important Notes
• Template file must exist — The .tpl file must already be saved in the MQL5 Templates folder. The script does not create templates, it applies existing ones.
• Case-sensitive name — Ensure the template name is entered exactly as the file is named, including capitalization.
• No .tpl extension needed — Enter only the name (e.g., MyTemplate), not MyTemplate.tpl.
• Failed charts — If a chart fails, it is listed in the report. Common cause: template file not found or incorrect name.
About RavexAlgo
RavexAlgo is a professional algorithmic trading brand dedicated to building high-performance Expert Advisors, utility scripts, and trading tools for MetaTrader 4 and MetaTrader 5. All products are developed with a focus on reliability, clean code, and real-world trading performance.
Visit us at: www.ravexalgo.com for more tools, EAs, and trading resources.
Official Links
