SimpleOrderPanel
A GUI order panel for MetaTrader that provides manual trading buttons (Buy/Sell, Close All, Close Buy/Sell, Breakeven, Partial Close, Modify SL/TP) and pending order placement via chart click. It supports risk-based lot calculation (balance percentage or fixed lots) and persists settings across sessions using global variables.
Open the interactive view (equity curve, symbol switch)Key facts
Backtest results (H1, about 1 year)
Not backtested yet — this EA could not be converted automatically.
Strategy analysis
This is not an automated trading strategy EA but rather a semi-automated trading utility panel. It does not generate its own trading signals; all entry decisions are entirely made manually by the trader. Entry conditions are triggered by the user clicking Buy/Sell buttons or by clicking on the chart to set pending order prices. Exit conditions include one-click close all positions, directional close (close buys or close sells only), moving stop loss to breakeven, and partial close functionality. Position sizing supports two modes: fixed lots mode and dynamic lot calculation based on account balance percentage, where the latter automatically calculates appropriate lot size based on stop loss distance and risk percentage. Money management ensures lot sizes comply with broker minimum/maximum/step constraints via the NormalizeLots function. Stop loss and take profit support both price mode and distance mode, with an optional auto-linked ratio relationship between them.
Strengths
- Rich UI with complete trading operations (buy/sell/close/breakeven/partial close/pending orders), greatly improving manual trading efficiency
- Supports balance percentage risk calculation mode that automatically calculates position size based on stop loss distance, helping control per-trade risk
- Compatible with both MQL5 and MQL4 via macro-based platform abstraction, ensuring good cross-platform compatibility
- Panel position and settings persist via global variables, auto-restoring after restart for a user-friendly experience
- Modular button visibility controls allow users to enable/disable feature zones as needed, keeping the interface clean and flexible
Weaknesses
- Requires modifying the standard library Dialog.mqh private variables to fix compilation issues, adding maintenance burden and being overwritten on each terminal update
- Stop loss/take profit modification applies to all qualifying positions simultaneously, lacking per-position selection which may cause unintended changes
- Partial close executes uniformly on all positions for the same symbol, unable to select specific positions for partial closing
- Pending order setup relies on chart clicks and continuously calls ChartRedraw on mouse move events, potentially affecting chart performance
- Lacks detailed feedback mechanism for trade execution results; error handling only outputs via Print, which users may not notice in time
Possible improvements
- Encapsulate Dialog.mqh modifications as an inherited class or patch file to avoid directly modifying the standard library, reducing maintenance after terminal updates
- Add position selection capability (e.g., click-to-select from a list) to make SL/TP modification and partial close operations more precise and controllable
- Add visual feedback for trade execution results (e.g., button color changes, popup notifications) instead of relying solely on Print log error notifications
Risk assessment
Overall risk: Safe
- Close All and directional close buttons can close all positions with one click, risk of accidental clicks but this is inherent to the tool's design
- SL/TP modification batch-affects all qualifying positions; if affectOtherTrades is true it may unintentionally modify non-panel positions
- Requires modifying standard library source code to fix compilation issues; improper modifications may affect other EAs' compilation
Evaluation scores
Parameters
| Parameter | Default | Description |
|---|---|---|
riskCalculation | FIXED_LOTS | Risk calculation mode: balance % or fixed lot |
stop_takeMode | ST_DISTANCE | SL/TP mode: by price or by distance |
bidAskReference | BA_NORMAL | SL/TP price reference: Bid/Ask/Reverse/Bid-only/Ask-only |
expertDeviation | 20 | Maximum slippage |
expertMagic | 450913 | EA magic number |
affectOtherTrades | false | Affect trades not opened by this panel |
showBuySellButtons | true | Show Buy/Sell buttons |
showCloseSepButtons | false | Show categorized close position buttons |
showSLBECloseAllButtons | true | Show breakeven and close all buttons |
showModifyButtons | false | Show modify SL/TP buttons |
showPartialClose | false | Show partial close function |
showPendingOrder | false | Show pending order button |
showDeleteOrder | false | Show delete pending order button |
showCommentEdit | false | Show order comment edit box |
grabSLwithDrag | false | Set SL via crosshair drag (distance mode) |
fontSize | 10 | Font size |
autoSetTP | 0.0 | Auto set TP as SL multiplier (0=disabled) |
autoSetSL | true | Auto set SL based on TP change |
asyncOperations | false | Use async order mode |
Similar Utility EAs
Backtests are historical simulations and do not guarantee future results. Not financial advice.