createNestedList (general description)

Syntax

<Local-table>.createNestedList(Column:integer, Row:integer[, Name:string]) → list

The method createNestedList creates a new sub-list or sub-table in the local variable designated by local-list or by local-table. The local variable has to be of data type list, stack, queue or table. The column type of this list or table has to be of data type list, stack, queue , or table as well.

Parameters

  • The parameter Column of data type integer designates the column of the cell.

  • The parameter Row of data type integer designates the row of the cell.

  • The optional parameter Name of data type string designates the name of the sub-list or sub-table to be created.

Return Value

The return value has the data type list which designates the nested list (DataList, DataQueue, or DataStack) that was created.

Example

var t: table[table]
t.create                -- creates a table
t.createNestedList(1,1) -- creates a sub-table
t[1,1][2,3] := "Hello world"
var subtable: table
MyDataTable.createNestedList(2,3) -- creates a sub-table
subtable := MyDataTable[2,3]
subtable.createNestedList(1,1)    -- creates a sub-table within a sub-table
subtable[1,1][4,4] := "Hello world"
Note:

This method also applies to sub-lists and sub-tables!

Related Topics

createNestedList for the DataStack and the DataQueue

createNestedList for the DataList

createNestedList for the DataTable