Skip to content
All library documents

Selecting the Current FORTS Futures Contract from Neighboring Expiries

Article MQL5 code base

Summary

The document describes three independent functions for identifying the nearest current FORTS futures contract. A user supplies the contract’s short name, such as a market abbreviation, and the script reports the full names of the previous, current, and next contracts.

The intended use is to help an Expert Advisor select the active contract for trading on a live account or in the strategy tester. This can support contract rollover logic, but the description does not explain how the functions determine which contract is current, how expiration dates or liquidity are handled, or how selection is validated. It includes no performance evidence or trading rules beyond contract identification.

Key ideas

  • The script identifies the current contract among neighboring FORTS futures expiries.
  • The user provides the futures short name as a parameter.
  • The output includes the full names of the previous, current, and next contracts.
  • The functions can be used to select a contract in an Expert Advisor for testing or live trading.

Tags

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