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

MT4 to MT5 Convertor (MT5Compat.mqh) - MetaTrader 4용 라이브러리

OrderManagement is by @fxSaber https://www.mql5.com/en/users/fxsaber
게시자:
Amirhossein Ghasemi Moroodi
조회수:
3740
평가:
(3)
게시됨:
2024.11.16 15:34
MQL5 프리랜스 이 코드를 기반으로 한 로봇이나 지표가 필요하신가요? 프리랜스로 주문하세요 프리랜스로 이동

📢 MT5Compat a Comprehensive MT4 to MT5 Conversion Library 🚀

A new interface library has been developed to simplify the process of converting MT4 indicators and Expert Advisors (EAs) to MT5. This library supports most of the MetaTrader 4 functions, offering developers a unified solution for cross-platform compatibility.

You can add this to both 


🌟 Key Features:

 Extensive MT4 Function Support: Seamlessly integrates widely-used MT4 functions into MT5 projects. (Order part created by @fxSaber)
 Customizable: Developers can expand the library by adding additional functions as required.
 Unified Codebase: Enables writing a single codebase that works flawlessly for both MT4 and MT5.
 Flexible Integration Options: The library can be included as a  .mqh  file or directly integrated into an EA or indicator.


🛠️ How It Works:

1️⃣ Integrate your MT4 EA or indicator code with the provided library functions.
2️⃣ Use the  .mqh  file to incorporate the library into your project.
3️⃣ Write your logic once and achieve full compatibility with both MT4 and MT5.
4️⃣ You need to replace these functions with the compat version in order to be compatible with both platform with same code


MT4 Function Cross-Compatible Replacement Description
Ask GetAsk() Retrieves the current Ask price for a symbol.
Bid GetBid() Retrieves the current Bid price for a symbol.
MarketInfo(symbol, MODE_DIGITS) GetSymbolDigits(symbol) Gets the number of decimal places for a symbol.
MarketInfo(symbol, MODE_TICKSIZE) GetSymbolTickSize(symbol) Retrieves the tick size for a symbol.
MarketInfo(symbol, MODE_TICKVALUE) GetSymbolTickValue(symbol) Retrieves the tick value for a symbol.
MarketInfo(symbol, MODE_MINLOT) GetSymbolMinLot(symbol) Gets the minimum lot size for a symbol.
MarketInfo(symbol, MODE_MAXLOT)   GetSymbolMaxLot(symbol)   Gets the maximum lot size for a symbol.
MarketInfo(symbol, MODE_POINT) GetSymbolPoint(symbol) Retrieves the point size for a symbol.
MarketInfo(symbol, MODE_SPREAD) GetSymbolSpread(symbol) Gets the spread for a symbol.
Close[x] iClose(symbol, PERIOD_CURRENT, x) Retrieves the close price of the bar at index x .
Open[x] iOpen(symbol, PERIOD_CURRENT, x) Retrieves the open price of the bar at index x .
Low[x] iLow(symbol, PERIOD_CURRENT, x) Retrieves the low price of the bar at index x .
High[x] iHigh(symbol, PERIOD_CURRENT, x) Retrieves the high price of the bar at index x .

🌐 Why This Library?

This interface library is a powerful tool for developers looking to:

  • Save time and resources by maintaining a single codebase.
  • Transition existing MT4 products to MT5 with minimal effort.
  • Customize and expand functionality for advanced solutions.

📂 Availability

The library is now available for integration into your projects.

For inquiries or feedback, feel free to contribute to the discussion below. Let’s make development faster, simpler, and more efficient for everyone!


Empowering developers for cross-platform trading solutions. 🌟



PPF - Past Present Future PPF - Past Present Future

The same PNB from Yousufkhodja Sultonov.

Range Forecast H1 Range Forecast H1

The indicator displays the actual range of the hourly candle in percent and the calculated range based on average statistics.

Range Levels Range Levels

The indicator draws the nearest levels of the specified price range.

BuySellZigZag BuySellZigZag

Double ZigZag draws virtual Buy and Sell levels on the price chart.