hi
i tested it ,your code works well.....
but that dosent fix the problem^^
i got the returnvalue like you said but its allways the same value no madder what the trend really is its 214783647 all the time.
i searched the value in the indicatorcode there are 3 buffers and the buffer that holds the 214783647 is the trend not the value that stored in it
like
if buffer1 holds the 214783647 means trend up,other 2 buffers holds then something like 174...
if buffer2 holds the 214783647 means trend down,other 2 buffers holds then something like 174...
could that cause the problem?
greets homi