G-Labs Trade Manager v4.0

The Ultimate Trade Management Panel for MT5 & MT4

Pure UI — No BMP Dependencies — Zero DLL

8 Trail Modes 4 Risk Modes Stealth SL/TP OCO Breakout Stats + Equity Curve News Calendar Currency Strength Grid Orders 7 Tabs 15+ Hotkeys CSV Export Close at Time Daily P/L Tracker

1Installation & Setup

MetaTrader 5

  1. Copy G-Labs Trade Manager v3.0.mq5 into your MQL5/Experts/ folder inside the MetaTrader 5 data directory.
  2. Restart MetaTrader 5 or press Ctrl+Shift+N to refresh the Navigator.
  3. Drag the Expert Advisor onto any chart.
  4. In the Inputs tab, configure your preferred settings (Magic Number, risk %, hotkeys, etc.).
  5. Click OK. The panel will appear in the top-left corner of your chart.
  6. Make sure AutoTrading is enabled (green play button on the toolbar).

MetaTrader 4

  1. Copy G-Labs Trade Manager v4.0.mq4 into your MQL4/Experts/ folder inside the MetaTrader 4 data directory.
  2. Restart MetaTrader 4 or press Ctrl+N to refresh the Navigator.
  3. Drag the Expert Advisor onto any chart.
  4. In the Inputs tab, configure your preferred settings (Magic Number, risk %, hotkeys, etc.).
  5. Click OK. The panel will appear in the top-left corner of your chart.
  6. Make sure AutoTrading is enabled (green play button on the toolbar).
See Section 23: MT4 vs MT5 Differences for a full comparison between the two versions.
The panel position is saved automatically. Drag the header bar to reposition it anywhere on your chart.

2Panel Overview

The panel is divided into a header bar, a tab bar, and a status bar. The MT5 version has 7 tabs (Trade, Pos, Tools, News, Alerts, Stats, Config). The MT4 version has 6 tabs (the News tab is not available on MT4).

Header Bar

Tab Bar

MT5: Seven tabs — Trade, Pos, Tools, News, Alerts, Stats, Config. Click to switch, or press 17.

MT4: Six tabs — Trade, Pos, Tools, Alerts, Stats, Config. Press 16.

Status Bar

The bottom bar shows live data at a glance:

ElementDescription
SymbolCurrent chart symbol in amber
Sp:Spread in points. Amber > 30pts Red > Max Spread
ML:Margin Level %. Color-coded: red < 200%, amber < 500%, normal otherwise
P/LFloating profit/loss across all positions
CountdownTime remaining until current candle closes (M:SS)
P:Number of open positions managed by this EA
SessionActive market session: TKY, LDN, NY (or overlap)
TimeServer clock time (HH:MM:SS)

3Trade Tab

The main tab for setting up and executing trades.

Account Info

Displays your Balance, Equity, P/L, and Free Margin in a compact two-column layout.

Risk Mode Selector

Four risk calculation modes are available as toggle buttons:

% Bal

Risk a percentage of your account balance per trade.

% Eq

Risk a percentage of current equity per trade.

Fixed $

Risk a fixed dollar amount per trade.

Lots

Use a fixed lot size regardless of SL distance.

Use the +/− buttons or type directly in the risk value field. Quick presets are available below (e.g., 0.5%, 1%, 2%).

RR Presets

Quick buttons to set the Risk:Reward ratio to 1R, 2R, or 3R.

SL / TP / RR Controls

Set your Stop Loss and Take Profit in pips, and the RR ratio. Each has +/− buttons for fine adjustment. The calculated Lot size, Risk $, and Reward $ are displayed live.

Live Trade Metrics

MetricDescription
ATR14-period Average True Range in pips (current timeframe)
PipVPip value in $ for the calculated lot size
MargEstimated margin required. Turns red if it exceeds free margin.

Breakeven & Trailing

Toggle BE and Trail on/off. Set the trigger value and choose between Pips or % of TP units. When trailing is ON, a row of 8 trail-mode buttons appears for quick switching.

RR Lock

When RR Lock is active, moving the SL (via +/− buttons or dragging the chart line) automatically adjusts the TP and all partial close levels to maintain your R:R ratio. This keeps your entire trade structure proportional as you fine-tune your entry.

Adjusting R:R Ratio

Use the / + buttons or type directly into the R:R field. When you change the ratio, the TP line and all partial close lines reposition automatically to match the new ratio, keeping everything in sync.

Partial Close (PC) Levels

Up to 4 partial-close levels (PC1–PC4) with adjustable percentages. Toggle PC on/off, or press Reset to restore defaults (25/50/75/100%). Partial close lines always adjust proportionally when the TP changes — whether from dragging, RR Lock, or ratio adjustments.

Trade Controls Row

ButtonFunction
LinesToggle draggable Entry/SL/TP/BE/PC lines on the chart
Order TypeCycle: Market → Buy Limit → Sell Limit → Buy Stop → Sell Stop. When a pending type is selected, a drag handle appears on the entry line and the entry stays where you place it.
FLIPSwap Buy/Sell direction while keeping SL/TP distances
VSL / Stealth SLVirtual SL hidden from broker
VTP / Stealth TPVirtual TP hidden from broker

Execution Helpers

Trade State Indicator

● READY TO TRADE — All checks pass. You can execute.

● BLOCKED: Spread 45 > 30 — One or more pre-trade checks have failed. The reason is shown.

Live BID / ASK / Spread

Displayed directly above the BUY/SELL buttons. The spread turns red when it exceeds your configured max spread.

BUY / SELL Buttons

Large, color-coded execution buttons. Labels change based on order type (e.g., "BUY LIMIT"). When Confirm mode is on, the first click arms the button ("CONFIRM BUY"), the second click executes.

When modifying a pending order (loaded from the Positions tab or a chart envelope), the TRADE button changes to a blue MODIFY button. Adjust the entry, SL, and TP lines on the chart, then click MODIFY to apply the changes to the existing order without placing a new one.

CLOSE ALL

One-click button to close all open positions managed by this EA.

4Risk Management

💰

% of Balance

Calculates lot size so that if your SL is hit, you lose X% of your account balance.

📈

% of Equity

Same as above but uses current equity instead of balance, accounting for floating P/L.

💵

Fixed Dollar

Risk a fixed dollar amount per trade regardless of account size.

📦

Fixed Lots

Use a specific lot size. Useful for scalping or when you want direct control.

The lot size is always clamped to the broker's min/max lot and step size. The panel will never exceed your configured maximum lot.

5Chart Trade Lines

When Lines is toggled ON, draggable horizontal lines appear on the chart:

LineColorPurpose
EntryAmberThe price where your order will be placed. For market orders, this follows the current price.
SLRedStop Loss price. Drag to adjust; the panel recalculates lot size in real-time.
TPGreenTake Profit price. When RR Lock is on, this moves automatically with SL.
BEBlueBreakeven trigger level (when BE is enabled).
PC1–PC4Lime shadesPartial close trigger levels.

A shaded zone between SL and TP visually shows the trade's risk/reward area. A TRADE button appears on the entry line for one-click execution, and a FLIP button lets you reverse direction.

Limit & Stop Order Drag Handle

When you select a pending order type (Buy Limit, Sell Limit, Buy Stop, or Sell Stop), a drag handle appears next to the FLIP button on the entry line. This small square button (labelled with the order type and direction arrows) lets you drag the entry price to your desired level without the line snapping back to market price.

Block Drag

Click and drag anywhere inside the shaded SL/TP zone to move the entire trade block (entry, SL, TP, partial closes) together. This is particularly useful for limit and stop orders — position your whole trade setup at once without adjusting each line individually. For pending order types, the block drag preserves the order type and entry price correctly.

Reset Lines

If your trade lines have become too spread apart (e.g., after dragging on a volatile chart), click the Reset button in the execution helpers row to snap all lines back to a manageable default distance from the current price. This resets the SL to 20 pips and the TP based on your current R:R ratio, bringing everything back into view.

Drag the SL line and the panel instantly recalculates your lot size, risk in dollars, and (with RR Lock) your TP level. Use the Reset button any time lines drift too far apart.

6Stealth SL/TP

Stealth mode hides your Stop Loss and/or Take Profit from the broker. Instead of placing a real SL/TP with the order, the EA monitors price locally and closes the position when the level is reached.

Why use Stealth mode?

  • Prevents broker stop-hunting on your exact SL price.
  • Hides your trade management strategy from the broker's book.
  • Useful when trading with brokers you suspect may widen spreads at SL clusters.

How it works

  1. Toggle VSL (Stealth SL) or VTP (Stealth TP) before placing a trade.
  2. The order is sent with SL=0 and/or TP=0 to the broker.
  3. The EA stores the virtual levels internally and monitors every tick.
  4. When price reaches the virtual level, the EA closes the position via a market order.
Stealth SL/TP requires the EA to be running. If MetaTrader is closed or the EA is removed, your positions will have no protection. Always have a backup plan.

78 Trailing Stop Modes

When trailing is enabled and the position moves into profit beyond the trail trigger, the SL is progressively moved to lock in gains. Choose from 8 modes:

ModeCodeDescription
FixedFixTrail by a fixed number of pips behind the current price.
ATRATRTrail by ATR value × multiplier. Adapts to volatility.
Moving AverageMATrail SL to the Moving Average price (e.g., 20 MA).
CandleCndlTrail to the previous candle's high (sells) or low (buys).
Parabolic SARPSARTrail to the Parabolic SAR indicator value.
FractalFracTrail to the most recent fractal high/low.
RR-BasedRRMove SL in increments as position reaches 1R, 2R, 3R of profit.
Profit %P%Lock a percentage of unrealized profit by adjusting SL.
When Trail:ON, the trail mode selector appears directly on the Trade Tab for quick switching. No need to visit Settings.

8Positions Tab

View Modes

Toggle between OPEN (live positions) and HIST (trade history).

Symbol Filter

Click the filter button (shows All or the current symbol name) to toggle between viewing positions for all symbols or only the current chart symbol. This is especially useful when trading multiple pairs simultaneously — quickly focus on just the positions relevant to the chart you're looking at. The filter setting is persisted between sessions.

Quick Action Buttons

Close All

Close all open positions instantly.

Close +

Close only positions currently in profit.

Close −

Close only positions currently in loss.

Flatten

Close-by opposing positions (hedge netting).

Position Rows

Each open position displays two rows of information:

Row 1 — Main Info & Actions

ColumnDescription
#Last 5 digits of the ticket number
SymSymbol name
TypeBUY (teal) or SELL (red)
LotsVolume
P/LProfit/loss including swap & commission
PipsDistance in pips from entry
MManage — load position onto chart lines
BEMove SL to breakeven + offset
1/2Close 50% of the position
CLOSEClose the entire position

Row 2 — Details

P/L Progress Bar

A thin color bar beneath each position shows where the current price sits between SL and TP. Green when in profit territory, red when closer to SL.

Chart Envelopes (Open Positions)

Every open position draws a compact envelope directly on the chart at its entry price. The envelope shows the ticket, direction, lot size, and current P/L at a glance.

Pending Orders

Listed below open positions with symbol, type, price, volume, a Mod button, and a Delete button for each.

Chart Envelopes (Pending Orders)

Pending orders also draw envelopes on the chart at their entry price level, styled in blue (buy-side) or amber (sell-side) to distinguish them from filled positions.

Summary

At the bottom: total open P/L, position count, win rate, profit factor, average win, and average loss for currently open positions.

History View

Switch to HIST to see closed trades over the last 7, 30, or 90 days with pagination.

9Tools Tab

Quick Actions

Close Buys

Close all buy positions.

Close Sells

Close all sell positions.

Close Profit

Close all profitable positions.

Close Loss

Close all losing positions.

Delete Pending

Delete all pending orders.

Reverse All

Reverse all open positions (close and reopen opposite).

Scale Out (2-Click Confirm)

Basket Management

Emergency (2-Click Confirm)

These are destructive actions. The first click arms the button (turns amber with "CONFIRM"), the second click executes.

Grid Orders

Configure Distance (pips), Count, and Multiplier (lot scaling). Then click Grid Buy or Grid Sell to place a ladder of limit orders.

Close at Time

Automatically close all open positions at a specific server time. Ideal for end-of-day or pre-news flat strategies.

When the set time arrives, all positions are closed, a toast notification is shown, and a sound alert plays. The timer automatically disables after triggering. The time setting persists between sessions.

10News Calendar Tab MT5 Only

Displays upcoming economic events from the built-in MetaTrader 5 calendar. This feature uses the MT5 CalendarValueHistory API and is not available in the MT4 version (MetaTrader 4 does not provide a built-in economic calendar).

Filters

Event Table

Shows day, time, remaining time, currency, event name, and previous/forecast/actual values. Actual values are color-coded vs. forecast.

Chart Integration

Toggle On Chart to display news markers directly on the chart as vertical lines.

Time Modes

Switch between Local, Server, and GMT time display.

11Alerts & Scheduler Tab

Price Alerts

Click Add Alert to place an alert line at the current price. When price crosses the line, a notification fires. Up to 5 active alerts.

Task Scheduler

Schedule automated actions at specific times:

Tasks can be one-time or recurring (weekly).

Over-Trading Monitor

Displays today's trade count vs. max, weekly count vs. max, and daily loss vs. limit.

12Stats Dashboard Tab

A comprehensive performance analytics dashboard calculated from your trade history.

P/L Summary Cards

Today

Profit/loss for trades closed today.

Week

Profit/loss for the last 7 days.

Month

Profit/loss for the last 30 days.

Trades

Total number of closed trades.

Win Rate Bar

A visual progress bar showing your win percentage. Green if ≥ 50%, red if below.

Key Metrics

MetricDescription
Profit FactorGross profit / gross loss. Above 1.0 is profitable.
ExpectancyAverage profit per trade. Positive means your edge is profitable.
Avg RRRealized average risk:reward ratio.
Avg Win / Avg LossAverage dollar amounts for winning and losing trades.
Max DrawdownLargest peak-to-trough equity decline.
Best / Worst TradeLargest single win and largest single loss.
Gross ProfitTotal profit from all winning trades.

Streaks

Maximum consecutive wins and maximum consecutive losses.

Equity Curve

A visual mini equity curve rendered directly in the panel using colored bars. Each bar represents a closed trade, plotted as cumulative P/L. Green bars indicate cumulative profit, red bars indicate cumulative loss. A zero line is shown when the curve crosses from profit to loss territory. Start and end values are labeled. This provides an at-a-glance view of your trading trajectory without leaving the panel.

CSV Export

Click the Export CSV button in the top-right corner of the Stats tab to export the last 90 days of trade history to a CSV file. The file is saved to the MT5 Files/ directory and includes:

Perfect for importing into Excel, Google Sheets, or journaling tools like Edgewonk and TraderVue.

Account Summary

Balance, Equity, Free Margin, and Margin Level % at the bottom of the tab.

13Settings Tab

General

News Filter MT5 Only

Trade Filters

Save / Load Settings

Save all current panel settings to a file, or load them back. Settings persist across restarts automatically.

14OCO Breakout System

OCO (One-Cancels-Other) lets you place a breakout setup where you anticipate a move in either direction but don't know which way.

  1. Click Box to draw a Hedge Box on the chart.
  2. Drag the top and bottom lines to define your breakout range.
  3. Click OCO to place a Buy Stop at the top and a Sell Stop at the bottom.
  4. SL for each order is placed on the opposite side of the range.
  5. When one order triggers, the other pending order is automatically cancelled.

Use Cancel to remove the OCO pending orders at any time.

15Grid Orders

Place a ladder of limit or stop orders with configurable parameters:

ParameterDescription
DistDistance between grid levels in pips.
CntNumber of orders in the grid.
MulLot multiplier for each subsequent level (e.g., 1.5x martingale or 1.0 for flat).

Click Grid Buy or Grid Sell to deploy. All orders use your current risk settings as the base lot.

16Basket Management

17Currency Strength Meter

Click CS on the header to open the Currency Strength Meter heatmap.

  • Displays relative strength (0–10) for major currencies, crypto, and metals — all sorted from strongest to weakest.
  • Calculation uses a weighted average of RSI values across M15 and H1 timeframes, normalised to a 0–10 scale.
  • Scores > 7 = Strong (Green)
  • Scores < 3 = Weak (Red)
  • Bar lengths are proportional to strength — stronger currencies have longer bars, weaker currencies have shorter bars, giving an instant visual comparison.
  • The heatmap window moves with the main panel.

Supported Instruments

CategoryInstruments
Forex MajorsUSD, EUR, GBP, JPY, AUD, CAD, CHF, NZD
CryptoBTC, ETH, LTC, SOL, XRP (compared against USD)
MetalsXAU (Gold), XAG (Silver) (compared against USD)

Exotic currencies are automatically filtered out. Only major currencies and your broker's available crypto/metal pairs are displayed, keeping the meter clean and relevant.

Smart Symbol Discovery

The meter automatically discovers crypto and metal symbols regardless of your broker's naming convention. Whether your broker lists Bitcoin as BTCUSD, #BTCUSD, BTCUSD.m, or BITCOIN, the meter will find and include it. Symbols are scanned from Market Watch first, then all broker symbols, with a final probe of common name variations.

Fast Recalculation

The symbol universe is cached after the first scan, so switching pairs or timeframes triggers an instant RSI recalculation without a full rebuild. Scores update smoothly without resetting to defaults.

Use the CSM to identify the strongest and weakest currencies, then trade pairs where you're buying strength and selling weakness. BTC and Gold are measured against USD, so their score reflects relative strength vs. the dollar.

18Hotkeys

Hotkeys are enabled via the InpHotkeys input. Press keys when the chart is focused:

KeyAction
17Switch to tab 1–7 (Trade, Pos, Tools, News, Alerts, Stats, Config)
BMarket Buy
SMarket Sell
CClose All Positions
EBreakeven All Positions
LToggle Trade Lines on chart
FFlip trade direction (Buy ↔ Sell)
DDelete all pending orders
RReverse all positions
HOpen hedge position
Shift+BPlace Buy Limit order
Shift+SPlace Sell Limit order
Shift+MMinimize / restore panel
Hotkeys only work when the chart window is focused. You can customize the Buy, Sell, Close All, and Breakeven keys in the EA inputs.

19Safety Features

Multiple layers of protection prevent accidental losses:

🛡

Margin Check

Blocks trade execution if required margin exceeds free margin.

Spread Gate

Blocks trades when current spread exceeds your max spread setting.

📰

News Filter

Blocks trading X minutes before and after high-impact news events.

📉

Drawdown Protection

Locks trading and optionally closes all positions when daily drawdown exceeds your limit.

🎯

Profit Target

Locks trading when daily profit target is reached, preventing over-trading.

🔒

Trade Confirmation

Two-click confirmation prevents accidental trade execution.

Over-Trading Protection

Limits trades per day, per week, and maximum daily loss.

🛑

Emergency Panic

Two-click panic buttons to instantly flatten everything.

20Notifications

TypeInputDescription
PushInpPushNotifySend push notifications to the MetaTrader mobile app.
EmailInpEmailNotifySend email alerts on trade events.
ScreenshotInpScreenshotAuto-capture a chart screenshot on trade execution.
SoundInpSoundAlertsPlay sound alerts for trades, breakeven, partial closes, and price alerts.
ToastBuilt-inOn-screen popup messages that appear above the status bar for 2.5 seconds.

21Profiles & Persistence

Quick Profiles (Trade Tab)

Three profile slots are available on the Trade tab:

Each profile stores: risk mode, risk %, lot size, SL/TP, RR ratio, virtual SL/TP, breakeven, trailing, and partial close settings.

Settings Persistence

All panel settings are automatically saved to an INI file when you close the chart or remove the EA. They are restored when you re-attach the EA. You can also manually save/load via the Settings tab.

Position State

Per-position state (breakeven status, trailing type, partial close levels) is persisted via MetaTrader's Global Variables, surviving EA restarts and terminal restarts.

22Input Parameters Reference

Panel

ParameterDefaultDescription
InpPanelX20Initial panel X position
InpPanelY40Initial panel Y position
InpMagic123456Magic number for order identification

Risk Management

ParameterDefaultDescription
InpRiskPercent1.0Default risk percentage
InpDefaultLots0.01Default lot size
InpMaxLots10.0Maximum allowed lot size

Trade Management

ParameterDefaultDescription
InpAutoBreakevenfalseEnable auto breakeven
InpBETrigger20.0Breakeven trigger distance
InpBEOffset2.0Breakeven offset (pips above entry)
InpAutoTrailingfalseEnable auto trailing stop
InpTrailStart20.0Trail activation distance
InpTrailStep5.0Trailing step size

Grid Orders

ParameterDefaultDescription
InpGridDistance20Distance between grid levels (pips)
InpGridOrders5Number of grid orders
InpGridMultiplier1.0Lot multiplier per level

Hotkeys

ParameterDefaultDescription
InpHotkeystrueEnable keyboard shortcuts
InpHK_BuyBBuy hotkey
InpHK_SellSSell hotkey
InpHK_CloseAllCClose All hotkey
InpHK_BEEBreakeven hotkey

Sessions

ParameterDefaultDescription
InpShowSessionstrueShow session boxes on chart
InpLondonStart/End7/16London session hours (GMT)
InpNewYorkStart/End12/21New York session hours (GMT)
InpTokyoStart/End0/9Tokyo session hours (GMT)

Notifications

ParameterDefaultDescription
InpPushNotifyfalseSend push notifications
InpEmailNotifyfalseSend email notifications
InpScreenshotfalseScreenshot on trade
InpSoundAlertstruePlay sound alerts

Equity Protection

ParameterDefaultDescription
InpUseMaxDDfalseEnable daily drawdown protection
InpMaxDD5.0Maximum daily drawdown (%)
InpUseProfitTargetfalseEnable profit target
InpProfitTarget3.0Daily profit target (%)

23MT4 vs MT5 Differences

G-Labs Trade Manager is available for both MetaTrader 4 and MetaTrader 5. The two versions share the same design, layout, and feature set wherever the platform allows. The differences below are caused by API and architectural differences between MetaTrader 4 and MetaTrader 5.

Feature Comparison

FeatureMT5MT4
Trade Tab — Risk modes, SL/TP, RR Lock, partial closes, breakeven, trailing, stealth SL/TP✓ Full✓ Full
Chart Trade Lines — Drag handle, block drag, reset, shaded zone✓ Full✓ Full
Positions Tab — Open trades, quick actions, chart envelopes, pending order modify✓ Full✓ Full
Tools Tab — Bulk close, scale out, basket, grid, close at time✓ Full✓ Full
News Calendar Tab — Economic calendar, filters, chart markers, news-based trade blocking✓ Full✗ Not available
Alerts & Scheduler Tab — Price alerts, task scheduler, over-trading monitor✓ Full✓ Full
Stats Dashboard — Performance metrics, equity curve, CSV export✓ Full✓ Full
Settings Tab — DD protection, profit target, spread/slippage filters, save/load✓ Full✓ Full
Currency Strength Meter — Forex, crypto, metals, proportional bars✓ Full✓ Full
OCO Breakout — Hedge box, paired orders✓ Full✓ Full
Hotkeys✓ Full✓ Full
Notifications — Push, email, sound, screenshot, toast✓ Full✓ Full
Profiles & Persistence✓ Full✓ Full

Tab Layout

MT5 (7 tabs)MT4 (6 tabs)
TradeTrade
PosPos
ToolsTools
News
AlertsAlerts
StatsStats
ConfigConfig

The MT4 version has 6 tabs. The News tab is removed because MetaTrader 4 does not provide a built-in economic calendar API.

Why No News Calendar on MT4?

MetaTrader 5 includes a native CalendarValueHistory function that provides real-time economic event data directly from MetaQuotes servers. MetaTrader 4 has no equivalent API. Rather than displaying an empty or non-functional tab, the MT4 build removes the News tab entirely and gives you a clean 6-tab layout.

Other Technical Differences

AreaMT5MT4
Order APIUses CTrade class, PositionSelect, OrderSend with request structUses classic OrderSend(), OrderSelect(), OrderModify()
Position modelNetting or hedging (broker-dependent)Always hedging (multiple positions per symbol)
Ticket typeulong (64-bit)int (32-bit)
Symbol infoSymbolInfoDouble(), SymbolInfoString()MarketInfo()
Input groupsinput group "..." supportedNo input groups (flat parameter list)
News-based trade blockBlocks trading before/after high-impact eventsNot active (no calendar data source)

Installation Paths

VersionFileInstall Location
MT5G-Labs Trade Manager v3.0.mq5MQL5/Experts/
MT4G-Labs Trade Manager v4.0.mq4MQL4/Experts/
Apart from the News Calendar, the MT4 and MT5 versions are functionally identical. All trading features, risk management, visual tools, currency strength, and panel controls work the same way on both platforms.
↑ Back to top