Inserts a column into the specified list browser control. Returns index of created column.
FUNCTION InsertLBColumn(
dialogID : LONGINT;
componentID : LONGINT;
columnIndex : INTEGER;
headerString : STRING;
width : INTEGER): INTEGER;def vs.InsertLBColumn(dialogID, componentID, columnIndex, headerString, width):
return INTEGER| Name | Type | Description |
|---|---|---|
| dialogID | LONGINT | id of the dialog that contains the list browser |
| componentID | LONGINT | id of the list browser control |
| columnIndex | INTEGER | index at which the column is to be inserted |
| headerString | STRING | text to set as column header |
| width | INTEGER | the width of the column in pixels |
width is specified in pixles
If you recursively use '0' as 'columnIndex' where to insert the new column, all column headers after the second will center the text label. Moreover they cannot be justified any longer.
If you insert an image to the List Browser, the second column header unexpectedly will display an image instead of text.
So don't use recursively zero for creating new columns. The issue disturbs quite a lot if you are loading columns from XML files, since the element reading starts from the end, so you'd like to add the columns always at top of the list.
(VW 12 - 13)
Availability: from VectorWorks11.0