MQLXpert TrailXpert
- Experts
-
Luke John Smith
I’m a full-time MQL5 developer.
I build Expert Advisors, indicators, dashboards and trading tools for traders who want real automation — not theory.
I specialise in turning manual trading strategies into clean, stable and fully automated systems that can run reliably in real market conditions. - Versione: 1.0
- Attivazioni: 5
MQLXpert TrailXpert
Automated Trade Execution and Trailing Stop Management for MetaTrader 5
MQLXpert TrailXpert is a configurable Expert Advisor designed to automate trade execution, continuous re-entry and trailing stop management.
Featuring four selectable trading modes, flexible position sizing and adjustable trade management parameters, TrailXpert allows traders to customise and optimise its behaviour according to their individual trading preferences.
Trading Modes
-
Buy Only: Automatically opens and manages buy positions, re-entering when the previous position closes.
-
Sell Only: Automatically opens and manages sell positions, re-entering when the previous position closes.
-
Automatic: Determines the trading direction using the previous completed candle's closing price relative to an Exponential Moving Average.
-
Hedging: Independently opens and manages buy and sell positions simultaneously. Requires a hedging account.
Key Features
-
Automatic trade execution and continuous re-entry.
-
Four selectable trading modes.
-
Customisable EMA period and timeframe.
-
Fixed lot or percentage-based position sizing.
-
Balance or equity-based risk calculations.
-
Adjustable initial stop loss.
-
Optional fixed take profit.
-
Configurable trailing stop activation, distance and step.
-
Automatic trailing stop management without widening existing stop losses.
-
Broker volume, margin and stop-distance validation.
-
Magic number-based position filtering.
-
Interactive on-chart control panel.
-
Pause and resume new entries without disabling existing position management.
How It Works
TrailXpert automatically opens positions according to the selected trading mode.
Each position is opened with an initial stop loss. Once price moves in favour of the position by the specified activation distance, the trailing stop begins managing the position.
When a position closes, TrailXpert automatically evaluates the entry conditions and opens a new position when permitted.
In Automatic mode, existing positions remain managed by the trailing stop even when the EMA direction changes.
Input Parameters
Trading Settings
-
TradingMode: Select Buy Only, Sell Only, Automatic or Hedging.
-
LotMode: Select fixed lots or risk percentage.
-
FixedLots: Fixed trading volume.
-
RiskPercent: Percentage of account balance or equity used to calculate position size.
-
UseEquity: Use account equity instead of balance for risk calculations.
-
MagicNumber: Unique identifier for positions opened by the Expert Advisor.
-
DeviationPoints: Permitted execution deviation in points, where applicable.
EMA Direction Filter
-
EMAPeriod: Period of the Exponential Moving Average.
-
EMATimeframe: Timeframe used for the EMA direction filter.
Stop Loss and Take Profit
-
InitialStopLoss: Initial stop-loss distance in points.
-
TakeProfitPoints: Fixed take-profit distance in points. Set to zero to disable.
-
TrailingActivation: Favourable price movement required to activate trailing.
-
TrailingDistance: Distance between the current closing price and trailing stop.
-
TrailingStep: Minimum improvement required before updating the stop loss.
Control Panel
-
ShowPanel: Enable or disable the on-chart control panel.
-
PanelX: Horizontal panel position.
-
PanelY: Vertical panel position.
How to Use
-
Attach TrailXpert to your preferred chart.
-
Configure the trading mode and position sizing.
-
Adjust the stop-loss and trailing stop parameters.
-
Configure the EMA settings if using Automatic mode.
-
Enable algorithmic trading.
Important Information
TrailXpert is a configurable automated trading system. The default settings are provided as a starting point for testing and optimisation.
Users should backtest and optimise their settings for their preferred instruments and timeframes before live trading.
Trading involves risk, and results will vary depending on the selected parameters, broker conditions and market behaviour.
Developed by MQLXpert
Code for Traders. By Traders.
