Building a Resizable Multi-Timeframe Chart Panel in MetaTrader 5
Summary
This article shows how to build a MetaTrader 5 indicator that displays several timeframe charts inside a chart subwindow. Buttons let users add chart objects for selected timeframes and toggle chart properties, including settings that are unavailable through the manual object controls. The chart objects are sized and positioned to fit the subwindow, with adjustments when the main chart or terminal window changes size.
The implementation uses a dummy indicator as a subwindow container, embeds that indicator as a program resource, and handles chart events to create, configure, and resize the objects. The article also explains that some properties, such as displayed bid and ask levels, require programmatic control. It is a platform interface and analysis workflow example rather than a trading signal or performance study. The author identifies symbol synchronization and ordering timeframes from lower to higher as possible extensions, indicating that those behaviors are not included in the described version.
Key ideas
- Chart objects can display multiple timeframes within a single MetaTrader 5 chart.
- A button panel can create timeframe views and toggle selected chart properties.
- A dummy indicator provides the subwindow used to contain the chart objects.
- Chart events can resize and reposition the objects when the window dimensions change.
- Symbol synchronization and automatic timeframe ordering are left as further work.
Tags
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.