Forex & EA basics
Stop-limit orders in MT5: two prices, two stages
A stop-limit order combines an activation condition with a limit-price requirement. It can express a breakout-then-pullback idea, but activation and execution are separate events. Seeing the trigger touched is not proof that a trade opened.
Follow both stages
When the stop condition is reached, a limit order is placed at the specified limit price. That order can remain unfilled. The broker must support the requested order type, and the price relationships must meet its rules.
An illustrative price path
Imagine a buy stop-limit trigger at 105 and a resulting buy limit at 103. If price moves from 104 to 106 and continues upward, the limit at 103 may never fill. If price later returns, it may become executable. These are invented prices, not a trading recommendation.
Inspect the right evidence
In a demo or visual test, record the original pending order, activation, resulting order and eventual deal or cancellation. Include both the trigger and limit prices in logs. A single entry arrow cannot explain the entire sequence.
Customise the waiting period
An editable EA can define how long the resulting limit order remains useful. Ask AI to trace what happens when the pullback never arrives, when the session ends and when the same signal appears again. Keep those choices explicit rather than silently replacing the limit with a market order.
Back to top












