![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
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
error 1 is a normal error...
in the tester, it usually does not occur (unless the code is curved and modifies unchanged order parameters or if the tester can generate slippages).
in the real market this (with correct order modification code) is possible when you change stops close to the market, especially with slippage - type of stop loss moves right behind the price when the order is moving to the positive and due to slippage and price movement, the error often occurs and it's clear why... good error...
Sorry, SellLimit requires dist:
not if (New_OOP < Bid) continue; butif (New_OOP-dist*Point < Bid) continue;
Boris, my fOrderModify() method takes into account all checks, both, on STOPLEVEL and FRIZLEVEL. So, if any of these conditions weren't met, the modification wouldn't have been completed.
You are absolutely wrong. The last error is still reset in many important functions. It works that way in WinAPI too.
So, save the error code into local variable right after it occurs, and don't try to use it after clearing this system variable ten times in mass of your intermediate functions.
Well, even if the error was overwritten as an option, the last one would still be there. The last error would still be 1 in my case. Isn't it so?
If I'm not even working with errors that way. Can I show you what you mean by an example?
Here's my modification function with all printers, because I'm debugging it now.(Ignore the other methods it uses).
The server responds: What do you want, old man?
Or: You tell me what you want, maybe I'll give you what you want.
I didn't get any criticism or a hearty Russian "merci". Sad, girls...
I didn't get any criticism or a hearty Russian "merci". Sad, girls...
Sorry, SellLimit requires dist:
not if (New_OOP < Bid) continue; butif (New_OOP-dist*Point < Bid) continue;
Victor, your first post already contained all the necessary information. You simply send orders to modify an order with no new values for that order's parameters.
Boris, let's assume that's the case... Assuming. But, if the function re-sends an order to modify the order, the significantton should be modified. And with me it doesn't modify at all. Even if we look at the log in the log, what we see is this:
Why is the order being sent? If its parameters weren't correct, the function would crash... And here it's kind of OK... ...it was sent. Then it turned out that there was an error. What is the logic behind it?What does this have to do with errors? I put an error print just before the modify function:
And here's the log of this piece of code:
You can clearly see that there are no errors before the modification function! What does this have to do with errors?