iCustom with REI

 

Hallo,

i tried to get the values of the REI by using iCustom(). But i dont get anything but Zero.


double val=iCustom(NULL,0,"RangeExpansionIndex",1,1,0);

 

What is wrong and can anyone help me?

Best Regards

Alex 

 
I don't know the indicator but for your iCustom call to work, it would need to have at least 2 buffers (0 and 1) and would also need to calculate values for the current bar as you are accessing index 0
 

Grüezi,

double val=iCustom(NULL,0,"RangeExpansionIndex",1,1,0);

of course you are getting always 0.0 (if you are using the REI that can be dldl from the net?)!

Buffer 1  doesn't exist (it has only 1 buffer) and the Period = 1 is what you want?

 

Thanks to every one,

you brought me on the right track!

 

double rei=iCustom(NULL,0,"RangeExpansionIndex",14,0,0); 

Best Regards!

Reason: