MT5 research beta · Expert advisor

TF Trade Manager for MT5

Study break-even, closed-bar ATR trailing and optional partial closing for one explicitly selected MT5 position ticket.

MQL5 source, EX5, README and SHA-256 checksums. Research beta.

Concept illustration for TF Trade Manager for MT5; not a software screenshot
Concept illustration; not a software screenshot or a performance result.
New research / Utilities

A management or logging tool, not a standalone return-generating strategy. Functionality is assessed through acceptance checks, not a profitability curve.

Functional workflow

How this utility is used

  1. Targets one exact position ticket on the chart symbol.
  2. Stores original adverse-stop distance and measures progress in R.
  3. Proposes break-even and closed-bar ATR trailing without widening an existing stop.

What this MT5 EA does

  1. Targets one exact position ticket on the chart symbol.
  2. Stores the original adverse-stop distance locally and measures progress in R.
  3. Proposes a break-even stop and optional closed-bar ATR trail; never deliberately widens an existing stop.
  4. Optional one-time partial close is restricted to hedging demo accounts.

Adjust the utility settings

Adjust the actual MT5 inputs below, then download a .set file. Load it through Strategy Tester → Inputs → Load. The EA ZIP includes source code and the compiled file.

Source defaults loaded.

Utility settings · 10 inputs

Changes apply to your downloaded file. They do not change the published tests.

Preview the .set file

Limitations and failure conditions

  • EnableDemoManagement and EnablePartialClose are false by default. All account-changing operations require demo/tester mode.
  • An initial adverse stop is required when original risk is first recorded. Break-even is entry price, not a fee-adjusted break-even.
  • Stored risk and partial-close flags use terminal Global Variables. Use the same terminal and retain those values for an existing ticket.
  • Partial close may not be possible at minimum lot sizes. Netting partial-close operations are intentionally unavailable.
  • Only one manager should control a given position. Network outages, broker rejections and terminal shutdown stop management.

Install in MetaTrader 5

  1. Extract the ZIP and read its README before attaching any file.
  2. In MT5, choose File → Open Data Folder. Copy the MQ5, EX5 and TFCommon.mqh files together into MQL5/Experts/TradeForex.
  3. Refresh Navigator and attach the EA to a chart in an isolated demo or tester. Review its inputs and data requirements.
  4. Use one instance per chart. Reattach after changing accounts; retain the documented state files and settings when testing restarts.

No broker password, web API key or DLL permission is required by this package.

Acceptance checks before relying on it

Native functional checks cover the recorded subset. The checklist below also includes cases that still require your own demo validation; not every scenario is certified as passed.

  • Verify that the wrong ticket and wrong chart symbol are ignored.
  • Check long and short break-even proposals, ATR values and stop/freeze-level rejection on demo.
  • Restart the EA and verify that its original-risk and one-time partial-close state persist.
  • Confirm that disabled management, a real account and an account switch cannot alter positions.

Download contents and integrity

The ZIP contains MQL5 source, the compiled EX5, TFCommon.mqh, README.md, MIT licence, TEST-STATUS.json and SHA256SUMS.txt.

ZIP size: 32,967 bytes. SHA-256: 78ebe4f43ea106fa22d13e775eddee68b9fcdcafc6504f47ced22a560e1bc851.

Download EA source and EX5

See how we distinguish compilation, demo testing and trading evidence.

Frequently asked questions

Does this tool work in MT4?

No. This package contains MQL5 source and an EX5 build for MetaTrader 5 desktop. MT4 requires a different codebase; mobile and web charts do not run this desktop file.

What has been tested?

The updated research build compiled with zero errors and zero warnings and passed the documented native functional acceptance checks. Netting and prolonged forward operation remain unverified. No profitability result is assigned to a management or logging utility.

Can it trade on a live account?

Order-changing functions in this release refuse real accounts and are disabled by default. Use an isolated demo or the Strategy Tester. The Execution Logger only records events and never sends orders.

Related tools and guides

Educational research, not personal investment advice. CFDs are leveraged products and can cause rapid losses. A calculation, indicator or stop cannot guarantee an account outcome.

Follow on Facebook