On Thu, Oct 3, 2019 at 11:36 PM Peter Bozek <[email protected]> wrote:
> > > On Thu, Oct 3, 2019 at 10:55 PM Chip Scheide via 4D_Tech < > [email protected]> wrote: > >> ok.. >> why does this not work??? >> >> in a loop >> For ($i;1;$Column_Count) >> INSERT IN ARRAY($Columns;1) >> OB SET($Columns{$i};<properties & values>) >> end for >> > > How it could? Line > INSERT IN ARRAY($Columns;1) > > tries to insert a real value of 1 as first element of array $Columns. If > $Columns is and object array, you should get an error, but uncompiled will > probably just retype array to array real? > I confused INSERT IN ARRAY with APPEND TO ARRAY, but would go with New object or OB COPY anyway. > > This could work > ARRAY OBJECT($Columns;$Column_Count) > For ($i;1;$Column_Count) > OB SET($Columns{$i};<properties & values>) > end for > > but did not tried that. > > > I would rather do > ARRAY OBJECT($Columns;$Column_Count) > For ($i;1;$Column_Count) > $Columns{$i}:=New Object(<properties & values>) > end for > > > -- Peter Bozek ********************************************************************** 4D Internet Users Group (4D iNUG) Archive: http://lists.4d.com/archives.html Options: https://lists.4d.com/mailman/options/4d_tech Unsub: mailto:[email protected] **********************************************************************

