Thanks Alex. seem to have figured it out:
Now I know I could just modify the In array in the function and because it's passed as a var (isn't it?) it would remain modified after the function, but my function is pretty complex and it's easier to make a new array and pass that out.
Anyway another question arise. Will BMax garbage collection handle this line:
myarray = ArrayFiddler(myarray)
properly because the original myarray is now being overwritten, all the strings in the original one need to be freed and so does the original array. Will that be done? I hope so...
Function ArrayFiddler:String[](In$[]) Local out$[] return out End Function Local myarray$[] myarray = ArrayFiddler(myarray)
Now I know I could just modify the In array in the function and because it's passed as a var (isn't it?) it would remain modified after the function, but my function is pretty complex and it's easier to make a new array and pass that out.
Anyway another question arise. Will BMax garbage collection handle this line:
myarray = ArrayFiddler(myarray)
properly because the original myarray is now being overwritten, all the strings in the original one need to be freed and so does the original array. Will that be done? I hope so...