[WARNING CLOSED!] Any newbie question, so as not to clutter up the forum. Professionals, don't go by. Can't go anywhere without you. - page 648

 

it is possible to change this parameter in the inite, but in the start it is questionable

int init()
  {
//---- indicators
   if (Period()>15)return;
   if (DrawZZ_TF1) SetIndexStyle(0,DRAW_SECTION,0,0,Red);
   else SetIndexStyle(0,DRAW_SECTION,0,0,CLR_NONE);
   SetIndexBuffer(0,ExtMapBuffer1);

  }
 
sanyooooook:

it is possible to change this parameter in the inite, but in the start it is questionable

The only difference is for commands to the preprocessor, everything else works anywhere, even in deinit.
 
sanyooooook:

it is possible to change this parameter in the inite, but in the start it is questionable

Urain:
The only difference is for commands to the preprocessor everything else works anywhere, even in deinit.
Been there, done that...
 

tried to write an indicator, it turned out that I don't understand at all which element number of the indicator buffer corresponds to an unclosed bar?

i.e.

buf[i] = EMPTY_VALUE;

what i equals ????

 
IgorM:

tried to write an indicator, it turned out that I don't understand at all which element number of the indicator buffer corresponds to an unclosed bar?

i.e.

buf[i] = EMPTY_VALUE;

what i equals ????

anything

if so

int i=0;

buf[i] = EMPTY_VALUE;

then i==0;

 
sanyooooook:

I.e. the rightmost bar which is not closed and is still being redrawn corresponds to the indicator buffer with index 0, and accordingly the first closed bar corresponds to index 1?
 
yes
 

is it possible to repaint a bar using an indicator?

i.e. the closed bar which corresponds to the indicator buffer buf[1] was a bearish candle I want to paint this bar with the indicator buffer colour

 

Good evening guys, advise how can be that on the marketinfo tradeallowed trading and at the same time error 133. i am still in diapers, and here i am stuck. and if the order without a specific financial instrument, it buys, but when i put the symbol of any pair in the buy operator, it gives 133. this is on the demo. advise please what may be the problem. thank you ))

 
freesenser:

Good evening guys, advise how can be that on the marketinfo tradeallowed trading and at the same time error 133. i am still in diapers, and here i am stuck. and if the order without a specific financial instrument, it buys, but when i put the symbol of any pair in the buy operator, it gives 133. this is on the demo. advise please what may be the problem. thank you ))

If your question is about the tester: in the tester you can only test the pair whose chart has been selected in the tester settings if the EA should open orders on a pair different from the selected one, then it will not work (but I have heard that it is possible to twist somehow)
Reason: