Questions from Beginners MQL5 MT5 MetaTrader 5 - page 303

 
mq35:

Normalize does not help. The same thing, sop-loss is not pulled up

--Create order -> ASK:1.3121 price:1.3111 sl 1.3106

buy limit 1.00 EURUSD at 1.3111 (1.3121) sl: 1.3106 (1.3118 / 1.3121 / 1.3118)
--Create Order <- result:10009

--Modify order -> price open:1.3111 BID :1.3119 sl 1.3107
order modified [#3 buy limit 1.00 EURUSD at 1.3111]

--Modify order <- result:10009

--Modify order -> price open:1.3111 BID :1.312 sl 1.3108
order modified [#3 buy limit 1.00 EURUSD at 1.3111]

--Modify order <- result:10009

--Modify order -> price open:1.3111 BID :1.3121 sl 1.3109
failed modify order #3 buy limit 1.00 at 1.31110 sl: 1.31080 tp: 0.00000 -> 1.31110, sl: 1.31090 tp: 0.00000 [Invalid stops]
--Modify order <- result:10016
Perhaps you are getting too close to the order open price.
 
For some reason I thought that if the price has already stepped FAR up, I could pull up the stop loss to the market by stepping over the opening price of the order... Is this not correct?
 
mq35:
For some reason, I thought that if the price has already stepped up a long time ago, then I can pull up the stop loss to the market by stepping over the opening price of the order... Is this not correct?

You have placed a buy-limit order at 1.3111 with a stop at 1.3106. The current Ask price is 1.3121. The order is still pending. And further on, according to the logs, it remains so. And you, as I understand it, start to trawl its stop. It succeeds at 1.3107, 1.3108... and then... ...apparently there is a broker's restriction - freezevel.

Freeze level - prohibition to modify orders located near the market. It is forbidden to modify, delete or close positions, which are close to execution.

To determine this you need to do so (MQL5):

SymbolInfoInteger( _Symbol, SYMBOL_TRADE_FREEZE_LEVEL );

And you, under no circumstances, can place a SL higher than the price of a buy-limit/buy-stop order until a trade has opened on the order and a position has opened.

 
Tapochun:

You have placed a buy-limit order at 1.3111 with a stop at 1.3106. The current Ask price is 1.3121. The order is still pending. And from here on in the logs, it stays that way.

The point is that the tester draws that a position is open for this order. it then closes it at the stop loss and calculates the income from the operation.
 
mq35:
That's the thing: the tester draws that a position has been opened for this order. it then closes it at the stop loss and calculates the income from the operation.
Then please send us the code. We can guess for a long time.
 
I have a question. I am using meta 4 from teletrade. What should I do? How do I close an order?
Files:
wawoy0.JPG  54 kb
 
albode:
I have a question. I am using meta 4 from teletrade. What should I do? How can I close an order?
The market is closed - this means that there is no quotation. Forex works 24 hours a day except Saturdays and Sundays. If the market is closed then no trading is possible.
 
albode:
I have a question. I am using meta 4 from teletrade. What should I do? How do I close an order?
Well, it's Saturday, judging by the publication date))
 
wait for trading to start on monday and the market to open....
 
albode:
I have a question. I am using meta 4 from teletrade. What should I do? How do I close the order?
find your key finder, he can open the market but only if he has the key to the market )
Reason: