And SL/TP (stops) need to be normalized to tick size (not Point) — ND code fails on non-currencies.
On 5Digit Broker Stops are only allowed to be placed on full pip values. How to find out in mql? - MQL4 programming forum (2011)
And abide by the limits Requirements and Limitations in Making Trades - Appendixes - MQL4 Tutorial and that requires understanding floating point equality Can price != price ? - MQL4 programming forum (2012)
Open price for pending orders need to be adjusted. On Currencies, Point == TickSize, so you will get the same answer, but it won't work on non-currencies. So do it right.
Trailing Bar Entry EA - MQL4 programming forum (2013)
Bid/Ask: (No Need) to use NormalizeDouble in OrderSend - MQL4 programming forum (2012)
SYMBOL_TRADE_FREEZE_LEVEL
is only when we want to modify a position?
SYMBOL_TRADE_FREEZE_LEVEL : Distance to freeze trade operations in points
SYMBOL_TRADE_STOPS_LEVEL : Minimal indention in points from the current close price to place Stop orders
My bot get a bug for the first order.
My code works fine for CFDs but not for crypto-currencies, what is the difference?
I will develop to function to normalize price and lots.
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hello, I develop an EA but sometimes, I get the error message:
I try to buy 0.1 BTCEUR and below are all informations I have about the BTCEUR:
I understand than the price to buy is 783.89, I put the stop loss at 772.1 (-1.5% from the bid price) and the take profit at 795.63 (1.5% from the bid price).
The point for the BTCEUR is 0.01 and the symbol trade stops level at 31.
If I am right, it means than the stop loss and the take profit must be at minimum 0.31 (0.01 * 31) from the bid price.
So, it should be good because I am at 11.77 (783.87 - 772.1) for the stop loss and at 11.76 (795.62 - 783.87) for the take profit.
What is wrong please?
What is missing?