Jan-HarmZ63:
Hi all,
I am trying to add elements (values of an indicator), tick by tick, to an array. I managed to do it with the following code but I imagine there is a more practical way without all of the shifting. And obviously the code below results in some lagging.
Is there an "array.SetAsSeries()" or something that automatically add and shift values to array[0].
PS: I am not a coder.
Thank you in advance.
Speed depending on how many elements you have.
string tmpArr[]; ArrayResize(tmpArr, 4); tmpArr[0] = "Button 1"; tmpArr[1] = "Button 2"; tmpArr[2] = "Button 3"; tmpArr[3] = "Button 4"; ArrayResize(tmpArr, 3); ArraySetAsSeries(tmpArr, true); ArrayResize(tmpArr, 4); tmpArr[ArraySize(tmpArr)-1] = "Button 0"; ArraySetAsSeries(tmpArr, false);
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
Hi all,
I am trying to add elements (values of an indicator), tick by tick, to an array. I managed to do it with the following code but I imagine there is a more practical way without all of the shifting. And obviously the code below results in some lagging.
Is there an "array.SetAsSeries()" or something that automatically add and shift values to array[0].
PS: I am not a coder.
Thank you in advance.