DIMENSION aMyarray [2, 11] >aMyarray = "ABC" >AINS (aMyarray, 10, 2)HTH
>DIME aMyarray[2,10] >>aMyarray = "ABC" >>=aIns(aMyarray,10,2)>The result is that the aMyarray[2,10] becomes the new value .F. instead of inserting a new column into this array.
1A 1B 1C 2A 2B 2Cand you DIME it to 2,4 you will get
1A 1B 1C 2A 2B 2C .F. .F.When you then insert a new column , =AINS(myArray,3,2) for example you get
1A 1B .F. 1C 2B 2C .F. .F.I believe I have seen some posts here a while ago which went into this in more depth.
PROCEDURE ins_new_column LPARAMETERS taOldArray,tnNewColumn lnOldRows = ALEN(taOldArray,1) lnOldCols = ALEN(taOldArray,2) lnNewCols = lnOldCols + 1 DIME taOldArray[lnOldRows*lnNewCols] FOR I = 0 TO lnOldRows-1 =AINS(taOldArray,tnNewColumn + (I*lnNewCols)) ENDFOR DIME taOldArray[lnOldRows,lnNewCols]so that INS_NEW_COLUMN myArray,3 would result in
1A 1B .F. 1C 2A 2B .F. 2C