Important: The information in this document is obsolete and should not be used for new development.
LAddColumn
You can use theLAddColumn
function to add one or more columns to a list.
FUNCTION LAddColumn (count: Integer; colNum: Integer; lHandle: ListHandle): Integer;
count
- The number of columns to add.
colNum
- The column number of the first column to add.
lHandle
- The list to which to add the columns.
DESCRIPTION
TheLAddColumn
function inserts into the given list the number of columns specified by thecount
parameter, starting at the column specified by thecolNum
parameter. TheLAddColumn
function returns as its function result the column number of the first column added, which is equal to the value specified by thecolNum
parameter if that value is a valid column number.If the column number specified by
colNum
is not already in the list, then new last columns are added. The value returned by theLAddColumn
function thus has significance only in this case.
Columns whose column numbers are initially greater than
- WARNING
- If there is insufficient memory in the heap to add the new columns, the
LAddColumn
function may fail to add the new columns although it returns a positive function result. Be sure there is enough memory in the heap to allocate the new columns before callingLAddColumn
.colNum
have their column numbers increased bycount
.If the automatic drawing mode is enabled and the columns added by
LAddColumn
are visible, then the list (including its scroll bars) is updated. New cells created by a call toLAddColumn
are initially empty.You may add columns to a list that does not yet have rows. The
dataBounds
field of the list record reflects that the list has columns, but you can only access cells when both rows and columns have been added.SPECIAL CONSIDERATIONS
You should not call theLAddColumn
function from within an interrupt, such as in a completion routine or VBL task.ASSEMBLY-LANGUAGE INFORMATION
The trap macro and routine selector for theLAddColumn
function are
Trap macro Selector _Pack0 $0004