You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Wrong type-receiver, you need to:
Learn programming.
Your build is also outdated. It does not have the requested modifiers yet. You need to update your MetaTrader 5 by connecting to the MetaQuotes-Demo server.
hi,
i prefer original mt5.
There's something I must not be grasping here. I don't see any overall benefit when it comes to hedging this way.
I mean, as I see it, the reason MQL5 never allowed hedging like this in the first place was because hedging a position by opening an opposite position is the same thing as simply closing the first one.
Why would a user prefer the "hedging system" to the "netting system"?
The only reason I could see for this implementation is more compatibility with brokers, somehow. Any insights here?
For me it was not obvious how to make a partial closing of a position like OrderClose function in mt4. I guessed that it is necessary to send a market request specifying the position identifier (request.position), the opposite direction of the trade and the number of lots to be closed. Without ordering the identifier, a new deal is opened. You can add this point to the article.
Slawa answered in detail here. Of course, I can't guess it at once.
How to determine SL and TP of closed positions is a mystery.
In other words, while the MT5 is advertised to have more features than MT4, it (in fact) restricts the traders' options.
This is how I see it and it wasn't really necesary for the traders as most of them are happy with MT4. It's like others have said, MT4 is for the traders, MT5 is for the brokers :)
This is a masterpiece!
Is this for the period of editing the history of trades a caveat, or will there never be 100% compliance?
Or is it about something else altogether (counter-closing, broker intervention)?
Chronologically
What the final ORDER_POSITION_ID will be equal to and how HistorySelectByPosition will work is still a question.
Obviously, one (out of two) opening trade in its DEAL_ORDER order will have DEAL_POSITION_ID != ORDER_POSITION_ID.
So you should not rely on HistorySelectByPosition even on Hedge.
Chronologically
What the final ORDER_POSITION_ID will be equal to and how HistorySelectByPosition will work is another question.
Obviously, one (out of two) opening trade in its DEAL_ORDER order will have DEAL_POSITION_ID != ORDER_POSITION_ID.
So you should definitely not rely on HistorySelectByPosition even on Hedge.
In my opinion, you are inventing problems out of nowhere. Well, a second position was opened (on a hedge account) on the balance of an order with a different Position_ID. Let's say. What is the problem with that? The positions will really be different. HistorySelectByPosition has nothing to do with it.
If you want to catch all the trades by a specific signal, you can set MagicNumber and unwind the chain yourself. 99.99% of traders will not understand your sadness.
In my opinion, you are inventing problems out of nowhere. Well, a second position was opened (on a hedge account) on the balance of an order with a different Position_ID. Let's say. What is the problem with that? The positions will really be different. HistorySelectByPosition has nothing to do with it.
We are talking about analysing the history of even manual trading, we are not talking about writing a TS.
For example, we want to understand how a trade slipped.I wanted to open a new demo account on MQL5 terminal. (There is already a netting demo account) When opening an account, the button "Use hedging in trading" is not activated.
Question: Can I have both hedge and netting forex accounts on the same terminal? Or should I reinstall the terminal?