Questions tagged [metatrader5]

MT5 Client Terminal trading platform and MT5 Server are parts of the Client/Server infrastructure for Brokers to provide brokerage services for clients, who can access and trade on Forex, CFD, Commodities, Futures, DeFi and equity markets. Both manual ( discretionary ) and algorithmic trading styles are supported on MT5 Client Terminal, mobile-based and web-based trading with also built-in and/or 3rd party assisted back-testing analyses tooling available.

MetaTrader 5, also known as MT5, was launched as a new product-line, after well known MetaTrader 4 platform has reached a phase of core-platform re-engineering.

MT5 is an electronic trading platform widely used by online retail foreign exchange speculative traders. It was developed by MetaQuotes Software and released in 2005. The software is licensed to foreign exchange brokers who provide, often branded under their respective names, the MT4/5-Terminal software to their clients.

The software consists of both a client and server components. The server-side, multi-host components are run by the broker, typically as a colocated infrastructure as close as possible to their FX-market liquidity provider DataCenter, and the client software is provided to the brokers customers, which use it to see live streaming prices, charts and to place orders as well as manage their account.

MetaQuotes head of sales, Anthony Papaevagorou, has announced MetaQuotes no longer intends to issue upgrades to the MetaTrader 4 (MT4) in favour of further promoting only the MetaTrader 5 (MT5) as the MetaQuotes' sole, flag-ship product [ reported on 2016-11-15 ]

287 questions
2
votes
2 answers

How to get OHLC-values from each new candle?

I am new in MQL5 and I am trying to capture the values of Open, High, Low and Close of each new candle. For now I am using a one minute TimeFRAME for each candle. I read the documentation and have not figured out how can I do it. My only clue was…
2
votes
1 answer

How to include Fibonacci levels in Expert Advisor (EA)?

I want to have access to various Fibonacci levels like 23.6%, 38.2%, 50%, 61.8% and 100% in my expert advisor (EA). How can I define those in my EA so that traders can select them via the inputs? I tried this input double Fibo=23.6; However, is…
Peter Simmons
  • 23
  • 1
  • 5
2
votes
3 answers

How can I use either < or > (or other comparative operator) in an expression depending on a function input?

I have two longish blocks of code that are identical except in various comparative statements > is switched with <, >= with <= etc. I wanted to put these in a function and use one operator or another depending on a function input. I am coding in…
whitebloodcell
  • 308
  • 1
  • 4
  • 10
1
vote
0 answers

Invalid Request 10013 trying to close order. Metatrader 5

I can successfully place order and retrieve the ticket id by result.order, but when i try to close the order always get invalid request 10013 using metatrading 5. Tried to close the order 2 ways. With the below function CloseTradeOrder AND using…
StackNet
  • 13
  • 3
1
vote
1 answer

How to compute lot size percentually having a stop loss on python using Metatrader

I am trying to compute lot size having stop loss (as price) but the lot size ends up quite big and eventually, I get an error: Error code: 10014 Error message: Invalid volume My current code is: import MetaTrader5 as mt5 def…
Amg91
  • 165
  • 8
  • 25
1
vote
0 answers

How can I enhance the ZigZag-Indicator in MetaTrader Terminal 5 to include bars and points for visualizing ranges?

Title :Enhancing ZigZag-Indicator in MetaTrader Terminal 5: Visualizing Range with Bars and Points Question : I'm looking to enhance the functionality of the ZigZag indicator in MetaTrader Terminal 5 by visualizing the range between the highest and…
1
vote
1 answer

cannot add the TradeRequest with server API in MT5

I am developing mt5 (MetaTrader 5) plugin. But I have one problem. I tried to make the TradeRequest and add it to request queue using server API, but I cannot find any additional request in request queue. The value of recode is 0 (it means…
zenith
  • 98
  • 1
  • 7
1
vote
0 answers

metatrader 5 don't let me make orders?

I get this error: AttributeError: 'NoneType' object has no attribute 'bid' from here price = mt5.symbol_info_tick(symbol).bid what's wrong?
Habi
  • 45
  • 6
1
vote
1 answer

Install MetaTrader5 using pip 22.3.1 and python 3.11.0 error

I am trying to install MetaTrader5 on windows using pip. python --version Python 3.11.0 pip --version pip 22.3.1 pip install MetaTrader5 ERROR: Could not find a version that satisfies the requirement MetaTrader5 (from versions: none) ERROR: No…
jayzee
  • 195
  • 1
  • 17
1
vote
0 answers

Error (-10005, 'IPC timeout') metatrader5 when initializing with Python

I've already connected to the mt5 terminal and server and gathered the data I wanted, but sometimes, almost randomly, the mt5.initialize returns the Error (-10005, 'IPC timeout') That's how I initialize it. import MetaTrader5 as mt5 # establish…
1
vote
2 answers

Converter bid/ask to OHLC formula

I can get bid and ask data from my market data provider but I want to convert this in OHLC values. What is the good calculation using bid/ask? I saw in a post that for a specific period: Open = (first bid + first ask) / 2. High = Highest bid Low =…
Teddol
  • 17
  • 2
1
vote
1 answer

MT5 || python: closing pending order after x minutes

I am using python connected to MT5, and have manage to load pending order with sl, tp, etc. I am now having problem expiring the pending order after 30 min, maybe, how do I put it in the request section? I have tried mt5.ORDER_TIME_SPECIFIED_DAY but…
1
vote
0 answers

numpy.core.multiarray failed to import when importing MetaTrader5

I tried to import MetaTrader5 as mt, but the following error is shown: ImportError Traceback (most recent call last) C:\\Users\\ESLAM\~1.SOB\\AppData\\Local\\Temp/ipykernel_13712/3445222804.py in \ \----\> 1…
1
vote
1 answer

Plotting two figures in one graph (Python)

I want to display two figures in one graph, so that they overlapping each other... here is my code: ohlc_data = pd.DataFrame(mt.copy_rates_range('EURUSD', mt.TIMEFRAME_D1, …
user18082564
1
vote
3 answers

Forex send orders using Python without Metatrader5

Need solutions to Forex order_send in Python. using Metatrader5 its so easy: import MetaTrader5 as mt5 request = { "action": mt5.TRADE_ACTION_DEAL, "symbol": symbol, "volume": lot, …
M.a.RS
  • 137
  • 2
  • 12