MetaTrader 4 MT4 Expert Advisors ChartButton Class MT4 – EA MetaTrader 4

ChartButton Class MT4 – EA MetaTrader 4

This class allows you to create buttons on the chart as if they were chart objects(have time and price coordinates) these objects can be dragged on the chart and when scrolling they stay at the same place. If you wan’t to learn some Object Oriented Programming or if you wan’t to understand how chartevents work or you wan’t to create graphical interfaces, you can learn a lot from this.

The main Idea behind it, is that it reacts to chart changes and mouse movements. If the mouse fits the given conditions the Button will be selected and will be draggable. I monitor the dragging with a custom chart event: EVENT_DRAG.The button’s onChartEvent function is always called in the built in OnChartEvent function, and it passes down the informations to the different handler functions.

Alternative:   AggZ - indicator MetaTrader 4

Check out the Tutorial video I’ve made to demonstrate the basic Ideas:


📈 ROBOTFX MetaTrader Expert Advisors and Indicators to maximize profits and minimize the risks