All about Calendar tab and Macro Economic Events. - page 7

 

Using the MQL5 Economic Calendar for News Filtering (Part 2): Stop Management Positions During News Releases

Using the MQL5 Economic Calendar for News Filtering (Part 2): Stop Management Positions During News Releases

In Part 1 we introduced a news-filter that blocks new trade entries during high‑impact events. That layer reduces entry exposure to abnormal volatility, but does not address the remaining issue: trades opened before the news window still experience widened spreads, transient spikes, and temporary distortions that can trigger SL/TP levels prematurely. Closing all positions before every news event is often not acceptable — it breaks trade structure, skews statistics, and conflicts with longer‑term logic.

This article addresses that specific engineering problem: how to add a controlled, reversible stop‑management layer that temporarily suspends stop‑loss and take‑profit levels for already open positions during the restricted news window and then restores them deterministically afterwards. The success criteria are explicit: actions must occur once per news window (no repeated modifications), original SL/TP values must be preserved and restored when technically possible, broker stop‑distance rules must be respected (no invalid placements), and the mechanism must be filterable by the EA (magic number) and clearly scoped (and the single‑symbol behavior is documented). The goal is mitigation of premature stop‑outs — not prediction of market direction.

Using the MQL5 Economic Calendar for News Filtering (Part 1): Implementing Pre- and Post-News Windows in MQL5
Using the MQL5 Economic Calendar for News Filtering (Part 1): Implementing Pre- and Post-News Windows in MQL5
  • 2026.02.18
  • www.mql5.com
We build a calendar‑driven news filter entirely in MQL5, avoiding web requests and external DLLs. Part 1 covers loading and caching events, mapping them to symbols by currency, filtering by impact level, defining pre/post windows, and blocking new trades during active news, with optional pre‑news position closure. The result is a configurable, prop‑firm‑friendly control that reduces false pauses and protects entries during volatility.
 

Using the MQL5 Economic Calendar for News Filter (Part 3): Surviving Terminal Restarts During News Window

Using the MQL5 Economic Calendar for News Filter (Part 3): Surviving Terminal Restarts During News Window

We already have a news filter that temporarily removes SL/TP and restores them after a news window in Part 2 of this series. The existing implementation, however, keeps its state only in memory: savedStops[] and the newsSuspended flag. If a restart or recompile occurs between SuspendStops(true) and SuspendStops(false), that in-memory state is lost. The EA no longer identify which positions had their stops removed. The result: open positions may remain unprotected or never be restored, and without a recovery mechanism, the system cannot safely reconstruct its previous state.

To address this, we define a recovery contract. The system must persist trade state externally: ticket IDs, stop levels, and suspension status. Upon reinitialization, this data must be restored accurately, ensuring that the system resumes operation without prematurely restoring stops or leaving trades unprotected.

Using the MQL5 Economic Calendar for News Filter (Part 3): Surviving Terminal Restarts During News Window
Using the MQL5 Economic Calendar for News Filter (Part 3): Surviving Terminal Restarts During News Window
  • 2026.03.31
  • www.mql5.com
The article introduces a restart-safe storage model for news-time stop removal. Suspension state and original SL/TP per position are written to terminal global variables, reconstructed on OnInit, and cleaned after restoration. This lets the EA resume an active suspension window after recompiles or restarts and restore stops only when the news window ends.
 

Using the MQL5 Economic Calendar for News Filter (Part 4): Accurate Backtesting with Static Data

Using the MQL5 Economic Calendar for News Filter (Part 4): Accurate Backtesting with Static Data

In Part 3, we solved the problem of state-loss during terminal restarts by introducing persistent storage using terminal global variables. The news-filter suspension system could now survive a VPS reboot or an EA recompile without losing track of which trades had their stops removed. That was a big step toward operational robustness.
Using the MQL5 Economic Calendar for News Filter (Part 4): Accurate Backtesting with Static Data
Using the MQL5 Economic Calendar for News Filter (Part 4): Accurate Backtesting with Static Data
  • 2026.04.28
  • www.mql5.com
This article implements a static, CSV-based news source for the Strategy Tester, so historical economic news events can be preloaded and queried during backtesting. It replaces live calendar calls in tester mode with a fast in-memory search, preserves the live logic for trading, and delivers deterministic, repeatable results with explicit control over included events, enabling reliable validation of news-aware filters, stop suspension, and trade-blocking rules.
 

MetaTrader 5 and the MQL5 Economic Calendar: How to Turn News into a Reproducible Trading System

MetaTrader 5 and the MQL5 Economic Calendar: How to Turn News into a Reproducible Trading System

Do you want news trading to work like an engineering problem — with clear rules, repeatable results, and automated testing? The purpose of this article is to demonstrate the working architecture of a news layer for MetaTrader 5: a single data source, proper use of the calendar API, a filtering and caching mechanism, export of historical events to a resource for the tester, and automatic switching between Live and Tester — so that the same code produces deterministic results in both real time and historical data.
MetaTrader 5 and the MQL5 Economic Calendar: How to Turn News into a Reproducible Trading System
MetaTrader 5 and the MQL5 Economic Calendar: How to Turn News into a Reproducible Trading System
  • 2026.05.08
  • www.mql5.com
The article presents a systematic approach to news trading in MetaTrader 5 using the built-in economic calendar: data structure, API functions, time synchronization rules, and event filtering. Methods of caching and incremental updating without overloading the server are described. The article also provides a working mechanism for exporting history to an .EX5 resource for deterministic testing using the same algorithm.
 

Trading with the MQL5 Economic Calendar (Part 11): Modular Canvas News Dashboard

Trading with the MQL5 Economic Calendar (Part 11): Modular Canvas News Dashboard

In this article, we address that gap. We rebuild the dashboard from the ground up. We replace chart objects with a canvas renderer and split the program into four dedicated modules, each responsible for one concern. The canvas drawing fundamentals, including rounded rectangle rendering, supersampling, anti-aliased primitives, and alpha compositing, are covered in depth in our MQL5 Trading Tools series. Readers who want a thorough understanding can refer to that series directly. Here, we focus entirely on what is new: the modular architecture, the dual theme system, the resizable layout, the collapsible day groups, the revised value tracking, and the live countdown with toast notifications.
Trading with the MQL5 Economic Calendar (Part 11): Modular Canvas News Dashboard
Trading with the MQL5 Economic Calendar (Part 11): Modular Canvas News Dashboard
  • 2026.05.26
  • www.mql5.com
We rebuild the MQL5 Economic Calendar dashboard from a monolithic object-based panel into a modular canvas-based system split across four files. The update adds a dual light and dark theme, collapsible day groups, a resizable layout with pixel-based scrolling, revised value markers, and a live countdown with toast notifications. A candidate event cache and a fast-path timer that repaints only changed cells improve responsiveness and make the codebase easier to extend.
 

Before trading with the Mql5 Calendar, It needs a serious fix. 

This happens on a daily basis. 

Edit: for context screenshot taken 16:57.
 

Trading with the MQL5 Economic Calendar (Part 12): SQLite Storage and Deduplication

Trading with the MQL5 Economic Calendar (Part 12): SQLite Storage and Deduplication

In algorithmic trading, the data feeding our automation must survive program restarts, terminal reboots, and the boundary between live charts and the strategy tester. In Part 11 of this series, we built a modular canvas-based news dashboard that loaded events either from an embedded Comma-Separated Values (CSV) resource in the strategy tester or from the live MetaQuotes Language 5 (MQL5) calendar API in live mode. That approach worked, but it left two problems unsolved. The CSV was a static snapshot frozen at compile time, so updating the test data meant recompiling the program. And the triggered trade list lived only in memory, so a restart erased every record of which news events had already fired trades, opening the door to duplicate orders. This article is for MetaQuotes Language 5 (MQL5) developers and algorithmic traders. It shows how to persist calendar and trade state across restarts, share one data store between live and tester modes, and download fresh history on demand without recompiling.
Trading with the MQL5 Economic Calendar (Part 11): Modular Canvas News Dashboard
Trading with the MQL5 Economic Calendar (Part 11): Modular Canvas News Dashboard
  • 2026.05.26
  • www.mql5.com
We rebuild the MQL5 Economic Calendar dashboard from a monolithic object-based panel into a modular canvas-based system split across four files. The update adds a dual light and dark theme, collapsible day groups, a resizable layout with pixel-based scrolling, revised value markers, and a live countdown with toast notifications. A candidate event cache and a fast-path timer that repaints only changed cells improve responsiveness and make the codebase easier to extend.
 

News Filtering with MetaTrader 5 Economic Calendar and CSV Fallback

News Filtering with MetaTrader 5 Economic Calendar and CSV Fallback

This article presents a news filter module developed using only built-in calendar functions. The module pauses trading before high-impact events, resumes automatically after a configurable post-release delay, and provides a secondary function that reduces position size rather than blocking entirely on days with multiple scheduled events. A companion logging script generates a CSV-based news calendar that the filter can read in the Strategy Tester, where the live calendar API is unavailable.
News Filtering with MetaTrader 5 Economic Calendar and CSV Fallback
News Filtering with MetaTrader 5 Economic Calendar and CSV Fallback
  • 2026.05.28
  • www.mql5.com
This article presents a self-contained news filter module for MetaTrader 5 built on the platform's economic calendar API. It implements symbol-to-currency mapping, pre- and post-event trading pauses, and optional position size reduction on high-impact days, with a CSV-based fallback for the Strategy Tester. A demo EA and live chart dashboard show integration and verification in both live and backtest environments.