This is additional code, not really good, you need direct access
Now I have it like this (hint from forum), but I'd like to avoid define
property can be put to each file individually (i.e. repeatedly and in different places), they have different scope than defines and variables. They are handled a little differently.
I don't see a logical method to move a property to const variables or defines. Backwards, yes, but not there :-)
Can you give me a trick (maneuver) to force the terminal to remember multiple values?
For example, a task:
Given N candles backwards. Find candlesticks with size >= X pips, memorize their number and size of each of them. If the current candle after closing is >= X pips, then compare its size with the total number of calculated candles and print the result - what is its size among all the candles found.
Ivan Butko #: Can you please suggest a trick (maneuver) to make the terminal remember multiple values?
For example, a task:
Given N candles backwards. Find candlesticks with size >= X pips, memorize their number and size of each of them. If the current candle after closing was >= X pips, then compare its size with the total number of calculated candles and display the result - what is its size among all the candles found.
The terminal remembers everything... the quotes archive!
And for the Expert Advisor or indicator you need this
I can't understand why there's an endless spell here
int GetMagic(Order &order)
{
int magic = 0;
//Если должен быть открыт стопордер и если есть уже открытые или отложенные //ордера, то возможно некоторые с маджиком, это надо проверить и сгенерировать //для нашего ордера уникальный маджик и отправить его на запись в массивif(order.cmd == OP_SELLSTOP || OP_BUYSTOP)
if(OrdersTotal() >= 1)
for(;;){
magic++;
for(int i = OrdersTotal(); i > 0 ; i --)
if (OrderSelect(i, SELECT_BY_POS, MODE_TRADES) != false)
if(magic != OrderMagicNumber())
return magic;
}
//Если нет открытых или отложенных ордеров то увеличиваем значение //маджика, чтобы он равнялся единице и отправляем на запись в массивelseif (OrdersTotal() == 0)
return (magic + 1);
return magic;
}
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.
But the question is why is there no access to
???
Yes and to
и
???
and why separate access when their values can be defined via define ???
think of it as a pragma in C/C++ - an instruction to the compiler
why separate access when their values can be defined via define ???
Think of it as a pragma in C/C++ - an instruction to the compiler
This is additional code, not quite good, you need direct access.
Now I have it like this (hint from forum), but I'd like to avoid define
This is additional code, not really good, you need direct access
Now I have it like this (hint from forum), but I'd like to avoid define
property can be put to each file individually (i.e. repeatedly and in different places), they have different scope than defines and variables. They are handled a little differently.
I don't see a logical method to move a property to const variables or defines. Backwards, yes, but not there :-)
Can you please suggest a trick (maneuver) to make the terminal remember multiple values?
The terminal remembers everything... the quotes archive!
And for the Expert Advisor or indicator you need this
like this:
I can't understand why there's an endless spell here
I can't figure out why there's an endless spell
is this a joke?
You have it in black and white for(;;)
Good afternoon.
Can you please tell me what function OrderSwap() is which returns the swap value of the currently selected order.
What if there is a grid of orders?
Does anyone have a function to calculate the sum of all swaps of a grid of orders for a magic order and a financial instrument.
Thanks for the help!!!