Hier nochmal der Loop, weil ich die Variable vergessen hatte. Im Editor war die Variable natürlich drin, trotzdem funktioniert es nicht, also daran lag es leider nicht.
bool Buycondition= false;
bool Sellcondition = false;
int x=1;
while(x>0)
{
if(iCustom(NULL,0,”Indicator”,0,x) <=-40) {Buycondition= true;break;}
if(iCustom(NULL,0,”Indicator”,0,x) <=-40)
{for(int y=1; y<x; y++) {if(iCustom(NULL,0,”Indicator”,0,x) >0) Buycondition =false; break; }}
if(iCustom(NULL,0,”Indicator”,0,x) >= 40) {Sellcondition= true;break;}
if(iCustom(NULL,0,”Indicator”,0,x) >=40)
{for(int z=1; z<x; z++) {if(iCustom(NULL,0,”Indicator”,0,x) <0) Sellcondition =false; break; }}
x++;}
|