FX Line Assistant
- Utilità
- Lee Teik Hong
- Versione: 1.11
- Aggiornato: 3 marzo 2026
- Attivazioni: 20
FX Line Assistant - Professional EA Description
Overview
The FX Line Assistant is an advanced MetaTrader 5 Expert Advisor featuring an intuitive visual trading panel that transforms horizontal chart lines into executable trade setups. This tool bridges manual technical analysis with automated trade execution, offering institutional-grade risk management and position monitoring capabilities.
Core Functionality
Intelligent Line Detection System
- Multi-Color Recognition: Automatically scans and identifies horizontal lines on the chart by color (Entry, Stop Loss, TP1, TP2)
- Tolerance-Based Matching: Configurable color tolerance (0-100%) enables detection of similar colors, accommodating variations in chart themes
- Dual Detection Method: Recognizes both EA-drawn lines and manually-placed chart objects (horizontal and trend lines)
- Real-Time Synchronization: Line modifications via drag-and-drop instantly update panel values and visual projections
Three-Tab Trading Interface
1. Main Panel
- Complete trade setup configuration
- Direction detection (Buy/Sell, Limit/Stop orders)
- Risk:Reward ratio calculation with quality indicators
- Toggle controls for Half-Close, Breakeven, and Trailing Stop features
- Quick-draw buttons for placing lines at current price
- One-click market and pending order execution
2. Symbol Summary
- Real-time monitoring of open positions on current symbol
- Live P&L tracking in both pips and currency
- Distance-to-level indicators for SL, TP1, TP2
- Position-specific breakeven status
- Net value calculations accounting for spread and commission
- Partial close and breakeven buttons for active positions
3. Today's P&L Dashboard
- Daily performance analytics for current symbol
- Win/Loss/Breakeven trade statistics
- Win rate percentage with color-coded indicators
- Gross profit and loss breakdown
- Total trades counter
- Auto-refreshing metrics
Advanced Risk Management
Dual Position Sizing Modes
- Fixed Lot Size: Traditional fixed-volume trading with +/- adjustment buttons
- Risk-Based Money Management:
- Fixed dollar amount per trade
- Percentage of account balance
- Auto-calculates optimal lot size based on SL distance
- Real-time lot estimation display
Sophisticated Exit Strategies
Partial Close & Breakeven (TP1 Hidden)
- Automatically closes 50% of position at TP1
- Moves remaining position's SL to entry price (breakeven)
- Prevents partial close if position hasn't reached profit
- Visual confirmation in Summary tab (✔ DONE indicator)
Half-Close Only Mode
- Closes 50% at TP1 without moving SL to breakeven
- Ideal for maintaining risk exposure on runner
- Mutually exclusive with Breakeven mode
Trailing Stop
- Activation threshold: Configurable profit in points
- Trail distance: Minimum SL distance behind current price
- Activates only after defined profit threshold reached
Visual Projection System
Forward-Looking Zones
- Risk Zone (Red): Projects SL area forward in time
- TP1 Zone (Teal): Visualizes first profit target region
- TP2 Zone (Blue): Shows final profit target area
- Implied Entry Line: Dashed line when entry not set (uses current price)
- Adaptive Colors: Auto-adjusts fill colors for light/dark chart backgrounds
- Configurable Duration: Projects forward N bars (default: 35)
Line Labeling System
- Real-Time Calculations: Shows distance (pips), net value (currency), percentage, and price
- Position-Aware: Adapts calculations based on open positions vs. planned trades
- Split-Scenario Logic: Correctly calculates TP values for half-close setups
- Beautiful Styling: Color-coded boxes with centered text, positioned at right edge
Automation & Safeguards
End-of-Day Management
- Auto-Expiry: Deletes pending orders X minutes before session end
- Configurable Timing: Set session end time and warning threshold
- Selective Deletion: Only removes pending orders (protects active positions)
- Status Notifications: Reports cancelled orders and any errors
Session Persistence
- Level Memory: Saves Entry, SL, TP1, TP2 across terminal restarts
- Symbol Tracking: Clears saved levels when changing symbols
- Settings Retention: Remembers Risk MM mode, toggle states, lot size
- Panel Position: Saves dragged location for next session
- Timeframe Detection: Auto-clears lines when timeframe changes
User Experience Features
Draggable & Scalable Interface
- Click-and-Drag: Repositions panel by clicking title bar
- Minimizable: Collapse to title bar to save screen space
- UI Scaling: Adjustable size (50%-200%) for different screen resolutions
- Mouse Scroll Protection: Disables chart scrolling while dragging
Professional Visual Design
- Material Design Colors: Clean, modern color palette
- Alternating Rows: Enhanced readability with row striping
- Color-Coded Feedback: Instant visual status using green (success), red (error), orange (warning)
- Responsive Layout: Adapts to minimized state and different tab contexts
Smart Trade Validation
- Pre-Execution Checks: Validates SL placement, TP distances, broker stop levels
- Direction Logic: Auto-detects Buy vs. Sell based on SL position relative to entry
- Order Type Selection: Automatically chooses Limit vs. Stop based on price levels
- Spread & Commission: Calculates total trade cost in net value displays
