G.M: how can initialize an array of string? If i use command ArrayInitialize(s,".")
- learn to code it, or pay someone. We're not going to code it FOR you. We are willing to HELP you when you post your attempt (using SRC) and the nature of your problem.
void ArrayInitializeString(string& A[], string init=""){ for(int iPos = ArraySize(A) - 1; iPos >= 0; --iPos) A[iPos] = init; }
What that so hard?
Sorry but I do not understand how angry your answer.
According to the official documentation on the function ArrayInitialize does not seem possible to directly initialize an array of strings.
I pointed to the part of my code related to my problem:
double sprd[116], swpL[116], swpS[116]; string s[116]; ..... ArrayInitialize(sprd, 99); ArrayInitialize(swpL, -99); ArrayInitialize(swpS, -99); ArrayInitialize(s, ".");
I was wondering if you could answer the question about initialize of an array of strings with an existing function.
From your answer I assume not, but I still wonder why it is not possible.
I take the trouble.
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
Hello,
how can initialize an array of string? If i use command ArrayInitialize(s,".") i get error :
ArrayInitialize - no one of the overloads can be applied to the function call.
Thanks in advance