[Archive!] Any rookie question, so as not to clutter up the forum. Professionals, don't pass it by. Couldn't go anywhere without you - 2. - page 493 1...486487488489490491492493494495496497498499500...537 New comment [Deleted] 2011.07.06 00:48 #4921 FOReignEXchange: Well, then you'd better post the code together with W. If it's not working, it must be wrong. this is the price zz "y" it changes in the comments it is calculated normally, is an integer int if(MathAbs(10 + 100*shift - y) <= 10) it changes in the comments... for(int shift=0; shift<19; shift++){ if(MathAbs(10 + 100*shift - y) <= 10) Comment("ура нашел",y); else Comment("кури бамбук",y);} But it categorically doesn't want to change the comment to the opposite one, I insert another condition in if works as it should, what's wrong with this if()? if(MathAbs(10 + 100*shift - y) <= 10) Денис 2011.07.06 00:56 #4922 In short, it all makes sense. [Deleted] 2011.07.06 13:44 #4923 I did it the other way around. The issue is resolved, thank you all. Владимир 2011.07.06 17:01 #4924 good afternoon, advise what is wrong here, trying to write the order type definition to the closing criteria if (Tip==0 && Opn_B==true) { if(bb<0 && bb1<0 || bb<0 && MA1 < MA2 || bb1<0 && MA1 < MA2) { Cls_B=true; } } Vadim Zhunko 2011.07.06 17:06 #4925 vilard: good afternoon, advise what is wrong here, trying to write the order type definition to the closing criteria if (Tip==0 && Opn_B==true) { if(bb<0 && bb1<0 || bb<0 && MA1 < MA2 || bb1<0 && MA1 < MA2) { Cls_B=true; } } Who knows your logic? But you need to know that OR has priority. Владимир 2011.07.06 17:13 #4926 how do I write to include the "and" first? [Deleted] 2011.07.06 17:30 #4927 Can you tell me why the array is not filling with values? It outputs zero. extern int n=15; // No. of bars int Total; // No. of calls to the start function int start() { if (Total>=1) return; // we need 1 time here Total++; double mas[]; for (int i=1; i<=n; i++) { mas[n]=iOsMA(NULL,0,9,21,5,PRICE_CLOSE,i); Print ("OsMA = ",iOsMA(NULL,0,9,21,5,PRICE_CLOSE,i)); } Print ("Array = ",mas[2]); Print ("Array = ",mas[10]); return; } New Bug How do you set [ARCHIVE!] Any rookie question, flintz 2011.07.06 17:34 #4928 Good evening ! int iBars( string symbol, int timeframe) . If I use symbol=NULL everywhere in the program, how do I know what symbol equals ? Виктор 2011.07.06 17:39 #4929 symbol=Symbol(); Vadim Zhunko 2011.07.06 18:00 #4930 vilard: how do I write to include the "and" first? You have to put parentheses in round brackets. 1...486487488489490491492493494495496497498499500...537 New comment
Well, then you'd better post the code together with W. If it's not working, it must be wrong.
this is the price zz "y" it changes in the comments it is calculated normally, is an integer int
it changes in the comments...
But it categorically doesn't want to change the comment to the opposite one, I insert another condition in if works as it should, what's wrong with this if()?
if (Tip==0 && Opn_B==true)
{
if(bb<0 && bb1<0 || bb<0 && MA1 < MA2 || bb1<0 && MA1 < MA2)
{
Cls_B=true;
}
}
good afternoon, advise what is wrong here, trying to write the order type definition to the closing criteria
if (Tip==0 && Opn_B==true)
{
if(bb<0 && bb1<0 || bb<0 && MA1 < MA2 || bb1<0 && MA1 < MA2)
{
Cls_B=true;
}
}
Can you tell me why the array is not filling with values? It outputs zero.
extern int n=15; // No. of bars
int Total; // No. of calls to the start function
int start()
{
if (Total>=1) return; // we need 1 time here
Total++;
double mas[];
for (int i=1; i<=n; i++)
{
mas[n]=iOsMA(NULL,0,9,21,5,PRICE_CLOSE,i);
Print ("OsMA = ",iOsMA(NULL,0,9,21,5,PRICE_CLOSE,i));
}
Print ("Array = ",mas[2]);
Print ("Array = ",mas[10]);
return;
}
Good evening !
int iBars( string symbol, int timeframe) . If I use symbol=NULL everywhere in the program, how do I know what symbol equals ?
how do I write to include the "and" first?