Android Question Array loses values

In my app I define a public array of 10000 chars.

I assign values to it in a sub and immediately after, log the value just written to it in order to confirm a "good write".

Later on, in another sub but in the same activity, i read that array one by one, in order to write the content to a text file.

However, most of the values disappear ("0"s appear instead, while others appear corrupted...

Any ideas ?