[ARCHIVE] Any rookie question, so as not to clutter up the forum. Professionals, don't pass by. Nowhere without you - 3. - page 532

 
FAQ:
in the case of the entry I have shown, the input variables, when changed in the function, will retain their changed values at the output of the function.
thanks a lot ... ))))
 
Tantrik:

Hi programmers! Is there a script that would not show pending orders in a window by opening time, but by instrument name and grouped them together?

When working with 10 currency pairs you cannot find the needed order. Does anybody have it?

See MetaEditor help for OrderSymbol()
 
Reshetov:
See OrderSymbol() in MetaEditor Help
Thanks, so you can change it yourself.
 
Tantrik:
Thank you, so you can change it yourself.
If no one forbids it and the potential opportunity is there, then it is possible.
 
Reshetov:
If no one forbids it and the potential opportunity is there, then you can.
Can you tell me where to find it? It's all in English.
 

What is the maximum bet on forex via MetaTrader 4? On my demo account I bet up to 50 tee. 51 does not work anymore. Can I change this number to a higher one? I looked in the settings of the program, did not find it. If I enter more than 50, the Sell and Buy buttons are deactivated.

If these parameters cannot be changed, please advise how to open several orders in a row without the price jumping away from the intended entry point.

For opening a new order we have the hotkey F9, but afterwards you have to click everywhere and it may take some time.

Is there a function in MT4 to close all orders at once? Or a hotkey to close them all at once?

 

Trying to find highs (no tails) for the subsequent day (for 1 hour frame)... making an indicator.

shows nothing...

int start()
{
int counted_bars = IndicatorCounted();
int lowest=0;
int highest=0;
//----
int limit;
//---- последний посчитанный бар будет пересчитан
if((counted_bars > 0))
counted_bars--;
limit = Bars - counted_bars;
//---- основной цикл

if ((Hour()> 0 && Hour()<=1 && Minute()>0 && Minute()<=1 ) ){

for(int i = 1; i < limit; i++)
{
//+++++++++++++++++++++++
for(int k = 1; k < 24; k++)
{if (iClose(NULL,0,k) >highest)
{highest=iClose(NULL,0,k);
}
}
ExtMapBuffer1[i] = highest ;

//+++++++++++++++++

for(int l = 1; l < 24; l++)
{if (lowest ==0) {lowest=iClose(NULL,0,l);}
if (iClose(NULL,0,l)< lowest) {lowest=iClose(NULL,0,l);} }
ExtMapBuffer2[i] = lowest;

//------------------
}
//----
return(0);
}

}

 
Tantrik:
Can you tell me where to find it? It's all in English.
Thanks, I got it.
 
DOCTORS:

Trying to find highs (no tails) for the subsequent day (for 1 hour frame)... making an indicator.

shows nothing...

int start()
{
int counted_bars = IndicatorCounted();
int lowest=0;
int highest=0;
//----
int limit;
//---- последний посчитанный бар будет пересчитан
if((counted_bars > 0))
counted_bars--;
limit = Bars - counted_bars;
//---- основной цикл

if ((Hour()> 0 && Hour()<=1 && Minute()>0 && Minute()<=1 ) ){

for(int i = 1; i < limit; i++)
{
//+++++++++++++++++++++++
for(int k = 1; k < 24; k++)
{if (iClose(NULL,0,k) >highest)
{highest=iClose(NULL,0,k);
}
}
ExtMapBuffer1[i] = highest ;

//+++++++++++++++++

for(int l = 1; l < 24; l++)
{if (lowest ==0) {lowest=iClose(NULL,0,l);}
if (iClose(NULL,0,l)< lowest) {lowest=iClose(NULL,0,l);} }
ExtMapBuffer2[i] = lowest;

//------------------
}
//----
return(0);
}

}

As soon as one o'clock in the morning, there will be a reading...
 

I can't understand the logic of the compiler. I have a function. I declare an external variable.

int start;

further the function body

double B()
{

int i=0, k=OrdersHistoryTotal();
for (i=k-1; i<=k; i++) {
if (OrderSelect(i, SELECT_BY_POS, MODE_HISTORY)!=false) {
if (OrderType()==OP_SELL) {
if(OrderProfit()< 0) {start=1;}

}

}

}

}

The value of the start variable must be memorized and equalized to zero when needed. But here it turns out that if OrderProfit()<0 , then start=1, and if OrderProfit()> 0 , then automatically start=0.

Have I understood the compiler's logic correctly?

Reason: