Array Bug or not Bug? - page 2

 

Should this work with string?
string time[4];
.
.
.
ArrayInitialize(time,"");

yes
 

Should this work with string?
string time[4];
.
.
.
ArrayInitialize(time,"");

yes

Slawa,
So how come that I am getting the following error?

2006.03.03 12:25:12 merlin4x19 EURUSD,M5: ArrayInitialize function does not process string arrays
Build 191, 02 March 2006.
 
Slawa,
So how come that I am getting the following error?

2006.03.03 12:25:12 merlin4x19 EURUSD,M5: ArrayInitialize function does not process string arrays
Build 191, 02 March 2006.

because in MetaQuotes language library under ArrayInitialize:

int ArrayInitialize( double& array[], double value)

Sets all elements of a NUMERIC ARRAY to the same value. Returns the count of initialized elements.
Note: It is not recommended to initialize index buffers in the custom indicator init() function as such functions are initialized automatically with an "empty value" at allocation and re-allocation of buffers.

Parameters:

array[] - Numeric array to be initialized.
value - New value to be set.

Sample:

//---- initializing of all array elements with 2.1
double myarray[10];
ArrayInitialize(myarray,2.1);
 

int ArrayInitialize( double& array[], double value)

Sets all elements of a NUMERIC ARRAY to the same value. Returns the count of initialized elements.

Thanks,

The point is:
I asked Slawa if the function "ArrayInitialize()" works with string array too;
He replied yes!
However, if I try to initialize string array I get error message "Array Initialize function does not process string arrays" which is contrary to Slawas reply.
So is it or is it not?
 

So how come that I am getting the following error?

2006.03.03 12:25:12 merlin4x19 EURUSD,M5: ArrayInitialize function does not process string arrays
Build 191, 02 March 2006.

Sorry, I've forgotten about such limitation
Reason: