Download MetaTrader 5
To add comments, please log in or register
Publish your programs in the Market. Make money with your knowledge!
moonsboy
889
moonsboy 2015.10.12 02:44 

 Does an Array have the maximum limit of dimension?

I can't find it in the help instruction.  Is it mentioned in the help instruction?

honest_knave
954
honest_knave 2015.10.12 07:06  

According to the documentation here:

The maximum admissible amount of dimensions in an array is four
moonsboy
889
moonsboy 2015.10.13 02:26  
honest_knave:

According to the documentation here:

The maximum admissible amount of dimensions in an array is four


Sorry for my wrong expression.

I mean the maximum limit of one dimension Array.  I can't find it in the help instruction.  Is it mentioned in the help instruction?

Keith Watford
Moderator
7887
Keith Watford 2015.10.13 05:32  

I think that it is 100 million for globally declared arrays

There is a 512kb limit on the amount of memory assigned to locally declared variables, so it could depend on what the array is storing.

moonsboy
889
moonsboy 2015.10.14 00:55  
GumRai:

I think that it is 100 million for globally declared arrays

There is a 512kb limit on the amount of memory assigned to locally declared variables, so it could depend on what the array is storing.

 

 

Thank you. May I know where you got it?
Keith Watford
Moderator
7887
Keith Watford 2015.10.14 01:59  
jollydragon:
Thank you. May I know where you got it?
I got an error when compiling some code with a very large Array range one time. As the error stated that it was too large for a locally declared variable, I tried declaring it globally and found that there was no error. Just out of curiosity I tried a larger array size until I found that 100 million was the maximum.
moonsboy
889
moonsboy 2015.10.15 01:38  
GumRai:
I got an error when compiling some code with a very large Array range one time. As the error stated that it was too large for a locally declared variable, I tried declaring it globally and found that there was no error. Just out of curiosity I tried a larger array size until I found that 100 million was the maximum.

 

Thank you very much for the sharing.  

/
To add comments, please log in or register