Going crazy - who can see the error by drawing the indicator

 

Hi,

I have programmed a customised indicator.

Everythink works perfekt but the last buffer isn't drawn and I can't understand why!

First try:
    
BuyBuffer[k] = (WL+WS)/2;
   if(SumBuffer[k]>WL)
   if(Sum2Buffer[k]<WL)
      {
       BuyBuffer[k] = EMPTY_VALUE;      
      }

So everything works fine. I see my line at the high of (WL+WS)/2 and on some short lines (they are about 2 or 3mm) I see the interrupts of the line (=the EMPTY_VALUE)

NOW I want to chance, that means I only want to draw the short lines if the conditions are true:

   BuyBuffer[k] = EMPTY_VALUE;    

   if(SumBuffer[k]>WL)
   if(Sum2Buffer[k]<WL)
      {
      BuyBuffer[k] = (WL+WS)/2;

      }

But now, I can't see any line - nothing! And I can't understand it!!

Does anybody can tell me why the first test is working and the second not?!

 

OK, I changed the

SetIndexStyle into "DRAW_ARROW"

and here

   if(SumBuffer[k]>WL)
   if(Sum2Buffer[k]<WL)
      {
       BuyBuffer[k] = SYMBOL_ARROWUP;     
      }
Now my problems are:

1.My indicator is in an seperate_window from 0 to 100 but the Symbol is drawn at the high of 253.707. How can I change it??

2.I allways get a cross as symbol even though I wrote SYMBOL_ARROWUP and SYMBOL_ARROWDOWN

I hope you can help my!

 

BuyBuffer[k] should probably be set to a value in the range of 0 to 100, by your description.

The value in the indicator buffer determines where something is drawn.

To pick an arrow style, see SetIndexArrow()

 

Lot's of thanks!! It works fine!