Building a Multi-Currency Expert Advisor with Timed Pending Orders
Summary
The article outlines a multi-currency Expert Advisor that trades with Buy Stop and Sell Stop orders. Its configurable controls define when a session starts, when new pending orders stop being placed, and when trading ends; at the end of the session, the system closes open positions and deletes pending orders. The example also includes stop loss, take profit, trailing stop, position reversal, and per-symbol volume settings.
The implementation validates time inputs, checks server time against each symbol’s permitted windows, and manages pending orders when one is triggered or a position closes. In reversal mode, it replaces the opposite pending order and can trail its level with price. The article then describes optimizing the parameters for two currency pairs separately and testing them together, selecting results by recovery factor. This is an implementation recipe, not evidence of a robust trading edge: the supplied excerpt gives no detailed test period, drawdown analysis, or out-of-sample validation, and its pending-order strategy is an example for adaptation.
Key ideas
- The Expert Advisor applies a pending-order strategy across multiple symbols.
- Separate time controls govern session start, the cutoff for placing orders, and session end.
- The system checks parameter validity and server time before managing orders and positions.
- In reversal mode, the opposite pending order is replaced after a trigger, with optional trailing behavior.
- The example optimizes two currency pairs and selects combined test results using recovery factor.
Tags
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.