View Single Post
Old 15th July 2009, 07:37   #126
Junior Member
Join Date: Apr 2009
Posts: 8
Re: Array Write fails to write empty strings

Originally posted by jerrydg
I have a couple of problems with NSISArray:

1. If I write to an index higher than one that has previously been written, that value is not actually written.
Don't skip over array indices. It's not really a random array, but if you pre-load things it will behave as you expect.

2. If I write a "" to an array element that previously contained a non-zero length string, that element is not set to the empty string. The write function seems to ignore an empty string parameter. This defeats the purpose of using an array to store user input that can legally be an empty string.
If you do:
${ArrayErrorStyle} MsgBox
at the start of the section you will get a big clue - hint: passing empty strings to macros is not necessarily a simple task.

Oh, and your example is missing a "${a1->Read} $tmp $i" from near the end of the loop (so it is working as written, not as intended).
grs1961 is offline   Reply With Quote