거래 로봇을 무료로 다운로드 하는 법을 시청해보세요
당사를 Telegram에서 찾아주십시오!
당사 팬 페이지에 가입하십시오
스크립트가 흥미로우신가요?
그렇다면 링크 to it -
하셔서 다른 이들이 평가할 수 있도록 해보세요
스크립트가 마음에 드시나요? MetaTrader 5 터미널에서 시도해보십시오
Experts

No Hedge Guard - close the newer side when a buy and a sell are open on one symbol - MetaTrader 5용 expert

Augusto Martin D'anna
Augusto Martin D'anna
MQL5 & Pine Script developer | Trader since 2019 | Strategy validation
As a trader, I know a bot is only as good as the logic behind it. I bridge
trading concepts and clean code: I don't just follow instructions, I make
sure your EA behaves exactly the way your strategy intends.
조회수:
36
게시됨:
cb_nohedge.png (78.73 KB)
MQL5 프리랜스 이 코드를 기반으로 한 로봇이나 지표가 필요하신가요? 프리랜스로 주문하세요 프리랜스로 이동

No Hedge Guard keeps a hedging account free of hedges. If a buy and a sell are open on the same symbol at the same time, it closes the newer side at once. It works for manual trades and for any EA, and it never opens trades.

Many prop firms do not allow hedging, and when two EAs trade the same symbol a hedge can appear by accident. Attach it to one chart and it watches the whole account.

How it works

  • OnTradeTransaction reacts to every new deal, and a 1-second timer checks again.
  • For each symbol it finds the oldest watched position (POSITION_TIME_MSC) and closes every newer position in the opposite direction.
  • Alert-only mode, optional magic number filter (0 = manual trades), status on the chart.

Inputs

  • When a hedge appears: close the newer opposite position, or alert only
  • Symbols to watch: all symbols or only the chart symbol
  • Magic numbers to watch, comma separated (empty = all)
  • Popup alert, status on the chart

Notes

  • It closes the position right after it opens; it cannot stop the order from being sent. Fix the cause too (for example, two EAs in opposite directions on one symbol).
  • On netting accounts a hedge is impossible, so there is nothing to do.
  • Tested on a MetaQuotes demo: a buy from one EA and a sell from another on EURUSD, the sell was closed immediately.
Chart Pattern Breakout Indicator Chart Pattern Breakout Indicator

Breakout status and measured targets for 13 chart patterns: channels, wedges and triangles found on zigzag swings, each shaded by what price did after its last swing (forming, broke up, broke down, target hit, failed) and rated with a quality score. Larger patterns stay around the smaller ones inside them, and same-size patterns never pile up.

Giano Session Range Breakout EA Giano Session Range Breakout EA

Night session range breakout for XAUUSD: one decision per day, a hash-chained journal written before every order, and safe recovery after restarts.

News Day Blocker - no new trades on US CPI and FOMC days News Day Blocker - no new trades on US CPI and FOMC days

Blocks new trades on US CPI and FOMC days (New York date). Built-in calendar 2015-2027, works in the Strategy Tester. Never opens trades.

NyTime - broker server time to New York time with US and EU daylight saving NyTime - broker server time to New York time with US and EU daylight saving

Converts broker server time to UTC and New York time with US and EU daylight saving rules. Works the same live and in the Strategy Tester, where TimeGMT() returns server time.