
Master the basics of MQL4 to automate trading strategies on the MetaTrader 4 platform, including creating indicators and expert advisors, and deploying robots or signals.
Discover three main parts of an MQL4 expert advisor: the initialize phase, on init, and the on tick function, with logging via prints to the experts log.
Explore basic data types in MQL4, including integers, doubles and strings, learn how to assign, print, and combine them, and understand implicit conversion and empty strings.
Master boolean types and expressions in MQL4, applying relational and logical operators (and, or, not) and grouping with brackets; use enum inputs to constrain user choices.
Explore arithmetic operations in MQL4, including addition, subtraction, multiplication, division and modulus with doubles, calculate averages of five numbers, and compare double vs integer types.
Declare and populate a five element array of doubles, access zero-based indices, and use a for loop to sum values and compute the average.
Explore how input parameters pass specifications to robots and set values for operations, then customize five user inputs, rename them with comments, and recalculate an updated average.
Build a MQL4 expert advisor that uses modulus a random number to detect odd or even, open buys or sells when trades are closed, with stop loss and take profit.
Learn to organize MQL4 code by turning trade commands into a reusable trade engine function, handling return types and inputs like volume, and calling it from on tick.
Learn to add a moving average filter to an expert, using an exponential moving average on close price to trigger buys above and sells below the moving average.
Add a parabolic SAR filter to the MQL4 expert with step 0.02 and max 0.2, using iSAR values to drive buys and sells and enforce one trade per candle.
Add a MACD filter to a MQL4 expert by configuring MACD inputs, reading main and signal lines, and buying when the main line exceeds the signal line and price confirms.
This lecture demonstrates implementing a trailing stop in a MQL4 expert advisor to maximize profits by moving the stop loss behind each profitable trade as prices move.
Create a basic custom indicator in MQL4, learn how indicators differ from expert advisors, and plot signal arrows when moving averages cross, using buffers, colors, and a candle-by-candle loop.
Add a moving average filter to a custom indicator and detect crossovers by comparing two moving averages over two candles, plotting buy and sell arrows when the cross occurs.
learn to copy and adapt existing signal conditions into an MQL4 indicator, using moving averages to generate buy and sell signals and validate entries across candles.
Learn how to use iCustom in MQL4 to call a custom indicator, retrieve its parameters and buffers, and generate buy and sell signals for a hedge ea with trailing stop.
Learn to automate a hedge in MQL4 by tracking the last trade's price, volume, and type, computing distance to entry, and closing open trades with a magic number.
Explore how hedge II implements a hedging strategy in MQL4, using hedge distance, stop loss, take profit, and a volume sequence that scales trades.
Learn how to use take profit and stop loss logic to close trades by identifying the youngest and oldest open trades and syncing with the last closed trade in history.
Consolidate the hedge logic by updating last price, last lots, and last trade from a single void function that does not return a value on every tick.
Hedge V session demonstrates fixing an error in the MQL4 code by validating the last close trade and first open trade in history; the instructor reviews and updates.
Create interactive buttons on charts using MQL4's object create for buttons, set colors, size, position, and text, then assign actions to execute buy or sell commands via an expert advisor.
Create a reusable button function to replace duplicated code. The function accepts name, color, width, height, position, and text to produce buy and sell buttons.
Learn to use the on chat event function in MQL4 to detect chart object clicks and trigger actions, such as tweet entry for buy or sell trades.
Learn how to create and position text labels on MQL4 charts, set fonts and colors, and build a reusable create_text function to display volume, stop loss, and take profit labels.
Learn to create input boxes and configure their attributes in MQL4, including chart id, name, type, position, size, width, height, font, and color, to build an interactive trading dashboard.
Create a green rectangle behind dashboard elements on the chart, set attributes and layering with the init function, and delete all objects during expert refresh to keep elements visible.
Read volume, stop loss, and take profit values from a display object via object get, converting strings to doubles on every tick.
Show me a man who doesn’t like the idea of making money while they eat, sleep or spend time with their families? Yes, we’re talking about automated trading here, and for this, you need reliable tools that will help you build your trading frameworks. MetaQuotes Language 4 (MQL4) is considered as a must programming language to build trading robots and technical market indicators now and for the future. Developing scripts and function libraries, MQL4 focuses on automating the trading processes and facilitate operational analysis. On top of that, MQL4 uses an extensive source code library for writing trading programs, directly addressing the needs and requirements of today’s traders. In this MQL4 tutorial, you’ll understand what is MQL4 in general, and learn about the various functions incorporated in the language that make it a perfect tool which will change the balance of your or your clients’ Forex trading accounts.
Build trusted automated trading frameworks to avoid hope trading
Automated trading is yet one more skill that you can learn and improve if you have the patience. Emotional trading or hope trading will not guarantee predictable results. The sad news is that somewhat 8 out of 10 will still rely on hope, which basically means that the rest 2 are getting their money from those 8. You need to learn to build the frameworks you can trust. MQL4 is aimed to do just that. To gain the insight of how Forex trading robots work, and help you leverage the knowledge to make a profit. That’s why you need an MQL4 tutorial to guide you through what you need to learn and provide you with practice opportunities.
What can you expect from this MQL4 tutorial?
Finding a comprehensive MQL4 tutorial is not an easy task. Most of the questions you’ll try sorting out online will eventually lead you to the Metatrader website where you can easily get puzzled or lost. The purpose of my course is to make you competent at the essential aspects of the MQL4. Here, you’ll walk much further from knowing what is MQL4 and what it does. We’ll progress from the beginner level to more advanced concepts. By the end of the course, you should be able to automate MetaTrader 4 strategies with ease.
If you take a look at the topic list of this course, you’ll see quite a lot of lines. We’ll study data types, custom indicators, scripts, function libraries to name but a few of the main fields. The important thing here is to learn how to fully automate Forex trading strategies so that you can code for traders.
Get the skills for today and years to come!
If you trade in financial markets yourself, or if you want to do the coding for other traders to get away from the emotional roller coaster, MQL4 is the skill that you need. With significant upgrades from previous versions, it’s a must for those who want to build trading bots today and in the future. Reserve your seat in this MQL4 tutorial and get ready to launch your career in the world of money.