The QUIT instruction in ProBuilder language is used to immediately stop a trading system. This command halts all trading activities, including the closure of any open positions and the cancellation of all pending orders such as stop and limit orders. Once a strategy is stopped using the QUIT instruction, it cannot be restarted automatically through code; manual intervention is required to re-launch the strategy.
QUIT
IF ShortOnMarket AND CurrentHour = 22 THEN
QUIT
ENDIF
IF StrategyProfit < -200 THEN
QUIT
ENDIF
This instruction is crucial for implementing risk management protocols within a trading strategy, allowing the trader to define specific conditions under which trading should cease to prevent further losses or to lock in profits under certain scenarios.