Wai Shing Ng: why i cannot assign Buy[i] into Dist[i]? I tested it in debug mode,when program run into for loop, it jumps to Test=321 directly and parameter in Dist[5] are 0. I also tried ArrayCopy,ArrayInsert,those cannot work. can anyone help me to solve this problem? Thank you very much.
double Buy() { double Dist[]; ArraySetAsSeries(Dist,true); ArrayResize(Dist,5,0); double Buy[5]={1,2,3,4,5}; for(int i=0;i<5;i++) { Dist[i]=Buy[i]; //P.S i tried ArrayCopy,ArrayInsert, those can't work } double Test=321; return (Test); }
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
why i cannot assign Buy[i] into Dist[i]? I tested it in debug mode,when program run into for loop, it jumps to Test=321 directly and parameter in Dist[5] are 0.
I also tried ArrayCopy,ArrayInsert,those cannot work.
can anyone help me to solve this problem?
Thank you very much.