Skip to content
All library documents

Buy Stop-Limit Orders with Fixed Risk Levels and Deposit-Based Sizing

Article MQL5 code base

Summary

This trading script is designed to place a buy stop-limit order using trigger distances measured from the current price. It also sets stop-loss and take-profit distances from the eventual opening price. The listed inputs cover the money-management ratio, the two trigger levels, protective and target distances, order expiry, and retry behavior after unsuccessful transactions.

The script’s stated sizing feature ties trade volume to a chosen proportion of the entire deposit. The document supplies configurable defaults for these parameters, but it does not show the implementation, explain how the broker interprets the points, or provide a trading signal for choosing the trigger levels. It gives no backtest or evidence of execution quality. Order expiry can be disabled, and retries are controlled by a repeat count and pause interval; appropriate settings depend on the instrument and trading environment.

Key ideas

  • The script places a buy stop-limit order with configurable trigger distances from the current price.
  • Stop-loss and take-profit distances are defined relative to the opening price.
  • A money-management input sets trade volume in relation to the deposit size.
  • Inputs also control order expiry and retries after unsuccessful transactions.
  • The document gives parameter descriptions but no strategy logic, code details, or performance evidence.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.