Retrieve values of prices from an indicator

 

Hi, I have purchased an indicator, which is of course protected.

My question is:

is it possible to retrieve the data that appear in the Data Window?

I mean for example, that I want to use Value 7 and Value 8. What code should I use? Because, I don't know in which way are named the buffers of the indicator. And 

so I was thinking to a way to retrieve the data directly from the chart or the Data Window, if it is possible.

Thanks for your help

 
marco_93:

Hi, I have purchased an indicator, which is of course protected.

My question is:

is it possible to retrieve the data that appear in the Data Window?

I mean for example, that I want to use Value 7 and Value 8. What code should I use? Because, I don't know in which way are named the buffers of the indicator. And 

so I was thinking to a way to retrieve the data directly from the chart or the Data Window, if it is possible.

Thanks for your help


Fairly easy. You use iCustom().


double  iCustom( 
   string       symbol,           // symbol 
   int          timeframe,        // timeframe 
   string       name,             // path/name of the custom indicator compiled program 
   ...                            // custom indicator input parameters (if necessary) 
   int          mode,             // line index 
   int          shift             // shift 
   );

Line index will be 6 and 7 as indicator buffers are indexed from 0 to 8 and not from 1 to 9. So Value 1 in the data window corresponds to indicator buffer 0 and hence, Value 7 and 8 correspond to indicator buffers 6 and 7. You then put 6 and 7 as mode parameter into iCustom() and it'll return the value of indicator buffers.

Reason: