How to return UsePeriod_5==false?
if((UsePeriod_5==true)&&(ContinueNext==true))
{
////////////////////
double OPEN_5=iCCI(NULL,0,5,PRICE_OPEN,0);
double CLOSE_5=iCCI(NULL,0,5,PRICE_CLOSE,0);
double HIGH_5=iCCI(NULL,0,5,PRICE_HIGH,0);
double LOW_5=iCCI(NULL,0,5,PRICE_LOW,0);
////////////////////
double BUY_CCI_5=0;
double SELL_CCI_5=0;
///////////////////////////////////////////////////////////////////////
if(OPEN_5 < -200) BUY_CCI_5=1;
if(OPEN_5 > 200) SELL_CCI_5=1;
}
I want... if(BUY_CCI_5+SELL_CCI_5 == 0) ...return( UsePeriod_5=false);
Any idea?
Then you must put this
I want... if(BUY_CCI_5+SELL_CCI_5 == 0) ...return( UsePeriod_5=false);
over the other code that follows and you must call the CCI Indicator int the variales BUY_CCI_5 and SELL_CCI_5 before you make the if statement
Then you must put this
I want... if(BUY_CCI_5+SELL_CCI_5 == 0) ...return( UsePeriod_5=false);
over the other code that follows and you must call the CCI Indicator int the variales BUY_CCI_5 and SELL_CCI_5 before you make the if statement
no.. i want a void or samething to return UsePeriod_5=false
Don't know how a void could return anything but how about this solution?
if((UsePeriod_5==true){ if(ContinueNext==true){ //////////////////// double OPEN_5=iCCI(NULL,0,5,PRICE_OPEN,0); double CLOSE_5=iCCI(NULL,0,5,PRICE_CLOSE,0); double HIGH_5=iCCI(NULL,0,5,PRICE_HIGH,0); double LOW_5=iCCI(NULL,0,5,PRICE_LOW,0); //////////////////// double BUY_CCI_5=0; double SELL_CCI_5=0; /////////////////////////////////////////////////////////////////////// if(OPEN_5 < -200) BUY_CCI_5=1; if(OPEN_5 > 200) SELL_CCI_5=1; } }else{ return( UsePeriod_5); }
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
How to return UsePeriod_5==false?
if((UsePeriod_5==true)&&(ContinueNext==true))
{
////////////////////
double OPEN_5=iCCI(NULL,0,5,PRICE_OPEN,0);
double CLOSE_5=iCCI(NULL,0,5,PRICE_CLOSE,0);
double HIGH_5=iCCI(NULL,0,5,PRICE_HIGH,0);
double LOW_5=iCCI(NULL,0,5,PRICE_LOW,0);
////////////////////
double BUY_CCI_5=0;
double SELL_CCI_5=0;
///////////////////////////////////////////////////////////////////////
if(OPEN_5 < -200) BUY_CCI_5=1;
if(OPEN_5 > 200) SELL_CCI_5=1;
}
I want... if(BUY_CCI_5+SELL_CCI_5 == 0) ...return( UsePeriod_5=false);
Any idea?