dollar index, please help me instead of drawing two arithmetic averages: ExtMapBuffer2[i] and ExtMapBuffer3[i] to draw one average and one exponential average
Can you please advise how easy it is to create an object and specify the bar time which is located to the right of the bar with an index of zero as the second time coordinate... Too bad the minus bars are not supported... ))
KRUSHNY: Please advise how to specify the time of the bar on the right side of the bar with index zero as the second time coordinate when creating an object... Too bad minus bars are not supported... ))
There is no such bar. It doesn't exist yet. But there is a way out - to declare a variable of the datetime type, enter there the zero bar opening time and add the number of seconds of one candle of the current timeframe to it.
I tried to attach function iMAOnArray() - but nothing, it's a weird situation with these built-in functions of calculation using passed parameter - array, not bars - I've tried to make any of these functions work, but there are also iCCIOnArray() and .....
I tried to attach function iMAOnArray() - but nothing, in general, some kind of mysterious situation with these built-in functions of calculation by passed parameter - an array, not by bars - as long as I twisted none of these functions work, but there are also iCCIOnArray() and .....
Maybe someone had a problem using two EAs on one chart.
The point is that one Expert Advisor (it is New_Platinum) draws lines on the chart from the beginning of the trading day, but starts trading only at 8 PM (terminal time). I don't know its algorithm (ex4 file), decompiling it does not provide any information.
The second Expert Advisor that trades on lines (there are a few of them and in principle any of them can be used).
However... they do not get along on one chart, and I cannot make crossing of two EAs. It is too early to order the creation of a new EA, because the assumed strategy is rather "raw".
Maybe there is a way to draw lines on two charts at once? Or there are some other options?
double Loss=0; // Последнее значение убыткаint i, k=OrdersTotal(), OrdTicket=-1;
for (i=k-1; i>=0; i--) { // Цикл по всем ордерам терминалаif (OrderSelect(i, SELECT_BY_POS, MODE_TRADES)) {
if (OrderMagicNumber()!=5100){
if ((OrderProfit()+OrderSwap()<0)) { // Если профит позиции меньше 0if (Loss>OrderProfit()+OrderSwap()) { // Если последнее значение убытка больше убытка позиции
Loss=OrderProfit()+OrderSwap(); // Значит тут убыток больше, запоминаем как последнее
OrdTicket=i; // Запоминаем номер убыточной позиции
}
}
}
}
}
If a position with magic 5100 is found in the loop, the loop must go to a new iteration:
if (OrderMagicNumber()!=5100)
... But that does not happen and the selected position with magic 5100 starts participating in further calculations as the most unprofitable position...
This is the locking position... And then another locking position is set on it ...
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.
If only it was Friday the 13th :-)
-Ns rnj &
-cvthnm
-ye b xnj &
-ye b dc`,e-uf-uf
nice technical indicator https://www.mql5.com/ru/code/9397
dollar index, please help me instead of drawing two arithmetic averages: ExtMapBuffer2[i] and ExtMapBuffer3[i] to draw one average and one exponential average
Please advise how to specify the time of the bar on the right side of the bar with index zero as the second time coordinate when creating an object... Too bad minus bars are not supported... ))
There is no such bar. It doesn't exist yet. But there is a way out - to declare a variable of the datetime type, enter there the zero bar opening time and add the number of seconds of one candle of the current timeframe to it.
Here you go, Igor :)
OK. THANKS A LOT!
I tried to attach function iMAOnArray() - but nothing, it's a weird situation with these built-in functions of calculation using passed parameter - array, not bars - I've tried to make any of these functions work, but there are also iCCIOnArray() and .....
OK. THANKS!
I tried to attach function iMAOnArray() - but nothing, in general, some kind of mysterious situation with these built-in functions of calculation by passed parameter - an array, not by bars - as long as I twisted none of these functions work, but there are also iCCIOnArray() and .....
Show me how you did it.
Maybe someone had a problem using two EAs on one chart.
The point is that one Expert Advisor (it is New_Platinum) draws lines on the chart from the beginning of the trading day, but starts trading only at 8 PM (terminal time). I don't know its algorithm (ex4 file), decompiling it does not provide any information.
The second Expert Advisor that trades on lines (there are a few of them and in principle any of them can be used).
However... they do not get along on one chart, and I cannot make crossing of two EAs. It is too early to order the creation of a new EA, because the assumed strategy is rather "raw".
Maybe there is a way to draw lines on two charts at once? Or there are some other options?
This Expert Advisor
Friends, I can't understand why it doesn't work:
If a position with magic 5100 is found in the loop, the loop must go to a new iteration:
... But that does not happen and the selected position with magic 5100 starts participating in further calculations as the most unprofitable position...
This is the locking position... And then another locking position is set on it ...
Help me to understand where the dog is hidden...