iCustom give a wrong output - page 2

 
krishna_gopal_2:
   Here I have attached the indicator.
What's that ? This is indicator doesn't compile.
 
angevoyageur:

In theory yes, but here he is only read 1 value so that doesn't make a difference.

I don't understand your problem, I can try to help you if you can provide the indicator's code.

OK,  good point,  do the arrays being used have a size of 0 elements ?  they would in mql4

double Sell_Signal[]; 
double Buy_Signal[];
 
angevoyageur:
What's that ? This is indicator doesn't compile.

Check this indicator. This is the original one I'm using. Just renamed it for avoiding lengthy name. 

 
krishna_gopal_2:

Check this indicator. This is the original one I'm using. Just renamed it for avoiding lengthy name. 

This one is ok, but it's absolutely not same as the first you have posted (bfs_stoc.mq5). I have checked and don't have any problem with this indicator.
 
angevoyageur:
This one is ok, but it's absolutely not same as the first you have posted (bfs_stoc.mq5). I have checked and don't have any problem with this indicator.
Me too have no problem with that indicator. While passing the values to an EA I'm getting very first value as an unknown value. Which should be zero most of the time or some Proper value. I tried so many conditions. But no use. Please help me out of it.
 
krishna_gopal_2:
Me too have no problem with that indicator. While passing the values to an EA I'm getting very first value as an unknown value. Which should be zero most of the time or some Proper value. I tried so many conditions. But no use. Please help me out of it.
Have you tried declaring your arrays correctly ?
 
RaptorUK:
Have you tried declaring your arrays correctly ?

1. Empty array - Same error (double arr[])

2. arr[1] - Same error

3. arr[0] - compiling error

4. arr[] = {0} - Same error

        2013.07.04 18:22:30 2013.01.02 04:07:00   Sell = 9.881312916824931e-324


 
krishna_gopal_2:

1. Empty array - Same error (double arr[])

2. arr[1] - Same error

3. arr[0] - compiling error

4. arr[] = {0} - Same error

        2013.07.04 18:22:30 2013.01.02 04:07:00   Sell = 9.881312916824931e-324


Please provide us the exact codes you are using, otherwise it's impossible to help you.
 
angevoyageur:
Please provide us the exact codes you are using, otherwise it's impossible to help you.

double Buy_Signal[];
double preBuy = 0;
double preSell = 0;
double Sell_Signal[];

void OnTick()
  {
     int Stoc_Handler = iCustom(_Symbol,PERIOD_H1,"Examples\\Stochastic_Cross_Alert_SigOverlayM_cw");
         int iBuy = CopyBuffer(Stoc_Handler,1,1,1,Buy_Signal);
         int iSell = CopyBuffer(Stoc_Handler,0,1,1,Sell_Signal);
         if(Buy_Signal[0] != Sell_Signal[0] && (Buy_Signal[0] != preBuy || Sell_Signal[0] != preSell))
         {
            Print("Buy = ", Buy_Signal[0]);
            preBuy = Buy_Signal[0];
            Print("Sell = ", Sell_Signal[0]);
            preSell = Sell_Signal[0];
         }
  }

 And you have the indicator with you.

Output is

2013.07.04 18:55:54 2013.01.02 04:07:00   Sell = 9.881312916824931e-324

2013.07.04 18:55:54 2013.01.02 04:07:00   Buy = 0.0

But there is no Signal in the chart by this time of output. This is only happening at the first time. And if there is a signal it works fine.

 
krishna_gopal_2:

 And you have the indicator with you.

Output is

2013.07.04 18:55:54 2013.01.02 04:07:00   Sell = 9.881312916824931e-324

2013.07.04 18:55:54 2013.01.02 04:07:00   Buy = 0.0

But there is no Signal in the chart by this time of output. This is only happening at the first time. And if there is a signal it works fine.

I can't reproduce this issue. Can you tell us how to reproduce it ?