Excuse me...... the martingale advisor, is it possible to prescribe a stoploss in it or is it not possible. Thank you.
The OrderSend() function has stop loss as one of its parameters. And it is it that sets the order. Therefore, we calculate the stop level for the order we need and enter it into the function.
Well, it will be - I told you that MY subroutines are involved! Remove them and replace them with your printers with GetLastError() query.
It's easy to do, if you're well-versed in mql. ) I'm just learning, so for me it's a bit difficult to remove all unnecessary things and leave only the necessary ones.
How iCustom is used with iCustom and an indicator that draws an arrow at some point to tell the EA to open .....
If iBands is an Ask > BBUP it is understandable but what about the object which may or may not show up (like arrow) ??????
All the same, you need to look at the code of the indicator, to understand which of the buffers contains the value of which line.
If you want to enter indicator parameters into iCustom function, then indicator parameters should be added to the Expert Advisor's custom variables. Otherwise, the EA will not understand what values are in the listed variables.
Hello! Please don't kick me if I'm asking the wrong question but I've dug all over the forum and the internet and haven't found what I'm looking for. The question is this! Is it possible to create a condition in if (after the last StopLoss (in time) should close eg 2 profit) until they are not doing else ... And if it is possible a small sketch in code, but it is possible and simply to draw a scheme in words - thanks in advance!
ruzzo: Hello! Please don't kick me if I'm asking the wrong question, but I dug the whole forum and the Internet and didn't find what I was looking for. The question is this! Is it possible to create a condition in if (after the last StopLoss (in time) should close eg 2 profit) until they are not doing else ... If possible, a small sketch in code, but you can just draw a scheme in words, thanks in advance!
In general, well, it's not clear what exactly you need.
A condition in if() can be inserted. It can be inserted after any event occurs. But what does it mean to close two profits? And else can be done. That's all...
if(условие){
// какой-то код
}
else{
// какой-то код
}
Actually, I don't understand what you actually need.
A condition in if() can be inserted. It can be inserted after any event occurs. But what does it mean to close two profits? And else can be done. The point is...
I understand that first the condition, and then the code, but I wanted to create a condition, I got StopLoss and work with another lot, for example - until I close the deal with two profits - I just do not want to compare the balance in if - all because if I compare the balance, and I have a pending order with a time limit - the changed lot skips by - because the order expires with the increased lot - maybe I'm not digging?
5 digits account. 1:500, lot 0.1 or 1, no difference, real account.
I've increased SL and TP 10-fold, nothing has changed, I've even changed more, no result, I can't get it to open something there ((
The fact that it works clearly, if I open a deal with my hands, then it transfers it to the no-loss position and starts trawling, but does not want to open it by itself!
What am I doing wrong, I can not understand for a week !??
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.
thanks
A lot of errors were found during compilation
Excuse me...... the martingale advisor, is it possible to prescribe a stoploss in it or is it not possible. Thank you.
The OrderSend() function has stop loss as one of its parameters. And it is it that sets the order. Therefore, we calculate the stop level for the order we need and enter it into the function.
compilation has revealed a lot of errors
Well, so it will be - I've warned you that MY subroutines are involved! Remove them and replace them with your printers with GetLastError()
Well, it will be - I told you that MY subroutines are involved! Remove them and replace them with your printers with GetLastError() query.
It's easy to do, if you're well-versed in mql. ) I'm just learning, so for me it's a bit difficult to remove all unnecessary things and leave only the necessary ones.
All the same, you need to look at the code of the indicator, to understand which of the buffers contains the value of which line.
If you want to enter indicator parameters into iCustom function, then indicator parameters should be added to the Expert Advisor's custom variables. Otherwise, the EA will not understand what values are in the listed variables.
Hello! Please don't kick me if I'm asking the wrong question, but I dug the whole forum and the Internet and didn't find what I was looking for. The question is this! Is it possible to create a condition in if (after the last StopLoss (in time) should close eg 2 profit) until they are not doing else ... If possible, a small sketch in code, but you can just draw a scheme in words, thanks in advance!
In general, well, it's not clear what exactly you need.
A condition in if() can be inserted. It can be inserted after any event occurs. But what does it mean to close two profits? And else can be done. That's all...
if(условие){ // какой-то код } else{ // какой-то код }Actually, I don't understand what you actually need.
A condition in if() can be inserted. It can be inserted after any event occurs. But what does it mean to close two profits? And else can be done. The point is...
Help plz to understand.
I decided to use the MACD Sample and I can not understand what's wrong - no matter what version, even the native one in the terminal.
all give out errors :
2011.02.28 23:01:53 MACD Sample EURUSD,M15: Error opening BUY order: 130
5 digits account. 1:500, lot 0.1 or 1, no difference, real account.
I've increased SL and TP 10-fold, nothing has changed, I've even changed more, no result, I can't get it to open something there ((
The fact that it works clearly, if I open a deal with my hands, then it transfers it to the no-loss position and starts trawling, but does not want to open it by itself!
What am I doing wrong, I can not understand for a week !??