I'll say as a coder who mainly writes on request: a couple of dozens of "extra" lines of code (when you understand what you've written there and you're confident in it), it's never redundant, at least in terms of reliability of the system as a whole, and respectively lesser number of returns and problems in communicating with the customer.
FAQ: I'm going to say as a coder, mostly custom-made: A couple of dozens of "extra" lines of code (when you understand what you've written there and you're confident in it) is never redundant, at least in terms of reliability of the system as a whole, and consequently fewer callbacks and problems in dealing with the customer.
I see. Thank you. I have already made the changes.
But all the same, it was interesting to me that it turns out that the opening can also be done with a "sloppy" volume... not quite as it should be, but the fact is...
The FAQ says it right. You can't rely on "defaults". Because I remember that 131 error (wrong lot) often came up, if you don't do a normalization before sending an order. Maybe now the MMOs have done their own default lot checking on the servers when sending an order for execution.
So you should always do your own price and lot normalization before sending.
This is a good coding rule for you, and a guarantee of less hassle with potential problems in the future.
Understood, thank you.
"Since I remember that 131 errors (wrong lot) often appeared if I didn't do any normalization before sending the order" - that's not the case now.
I accidentally checked it myself, when I "forgot" to enable the lot normalization feature.
It would be nice to automate this process, i.e. to do this job beforehand instead of waiting for profit to trigger. i looked through all of the posted scripts, i found a similar one, but they say it doesn't work. it' s for clarity. Or let's make a function that when a TP or SL triggers, the script opens all just closed orders, only in a pending form. Many traders know what they are going to do in a certain situation and it's very convenient to do that before the situation happens.
sting-igor: It would be nice to automate this process, i.e. to do this job beforehand instead of waiting for profit to trigger. i looked through all of the posted scripts, i found a similar one, but they say it doesn't work. it' s for clarity. Or let's make a function that when a TP or SL triggers, the script opens all just closed orders, only in a pending form. Many traders know what they are going to do in a certain situation and it's very convenient to do that before the situation happens.
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
I'm going to say as a coder, mostly custom-made: A couple of dozens of "extra" lines of code (when you understand what you've written there and you're confident in it) is never redundant, at least in terms of reliability of the system as a whole, and consequently fewer callbacks and problems in dealing with the customer.
I see. Thank you. I have already made the changes.
But all the same, it was interesting to me that it turns out that the opening can also be done with a "sloppy" volume... not quite as it should be, but the fact is...
The FAQ says it right. You can't rely on "defaults". Because I remember that 131 error (wrong lot) often came up, if you don't do a normalization before sending an order.
Maybe now the MMOs have done their own default lot checking on the servers when sending an order for execution.
So you should always do your own price and lot normalization before sending.
This is a good coding rule for you, and a guarantee of less hassle with potential problems in the future.
Understood, thank you.
"Since I remember that 131 errors (wrong lot) often appeared if I didn't do any normalization before sending the order" - that's not the case now.
I accidentally checked it myself, when I "forgot" to enable the lot normalization feature.
I see. Thank you. I've already made the changes.
But it was still interesting to me that it's possible to open with a "sloppy" volume... not quite as it should be, but the fact is...
Before the introduction of the five digits, no one asked the question of normalisation at all - everything worked as it was.
Can you tell me what's the problem? Below if you need the code.
Fig.1
Fig. 2
It would be nice to automate this process, i.e. to do this job beforehand instead of waiting for profit to trigger. i looked through all of the posted scripts, i found a similar one, but they say it doesn't work. it' s for clarity. Or let's make a function that when a TP or SL triggers, the script opens all just closed orders, only in a pending form. Many traders know what they are going to do in a certain situation and it's very convenient to do that before the situation happens.
You're in the right place :Work
Can you tell me what's the problem? Below if you need the code.
Fig.1
Fig. 2
I'm sorry that the question was asked a second time.
Compare your variant with this
It still doesn't work correctly, but it's better
Edited the indicator again
You go this way:Work
Doesn't anyone have one?
DigCode Base
If you can't find one, then order one.