DisplayBox.newColumn

Availability

Flash Player 7.

Usage

DisplayBox.newColumn([ColumnName,ColumnWidth,isHTML,isEdit,WordWrap,isVisible,HeaderName,ColumnLength])

Parameters

ColumnName Optional; The name used to reference the column for with other functions. default: : F# (where # is the Column Number) ie F1 or F2

ColumnWidth Optional; The width of this column. default: : 100

isHTML Optional; Specifies if this column displays html text. default : false

isEdit Optional; If set to true, will allow this column to be edited when the row is clicked on. This will then fire the EditChange event when the row looses focus. default : false

WordWrap Optional; Specifies if text wraps to the next line. default : false

isVisible Optional; Specifies if the column is visible to the user. Using invisible columns can be useful when there is additional data you need to store for each row but do not need it to be visible to the user. default : false

HeaderName Optional; The name displayed in the column header. default : blank

ColumnLength Optional; The maximum number of characters the specified column can hold. default : 0 (unlimited)

Returns

True if the column was created, and false if the function was called after the DisplayBox.InitBox() was called. All columns must be created before calling DisplayBox.InitBox().

Description

Function; Adds a new column to the DisplayBox.

Example

The following will assume you did not add any columns using the parameters tab in the GUI. This will construct a DisplayBox with 3 columns, all will automatically size itself to display all 3 columns and up to 6 rows before showing the scrollbars. We will set the Email Address column to enable HTML text, this way we can make the email address a clickable link and initiate a mailto.

//construct columns

myDisplayBox.newColumn("WholeName",250,false,false,false,true,"Contacts Name",60);
myDisplayBox.newColumn("Phone",150,false,false,false,true,"Phone Number");
myDisplayBox.newColumn("Email",175,true,false,false,true,"Email Address "); //We set isHTML to true so we can easily do mailto's to this contact
myDisplayBox.autoResize=true;
myDisplayBox.DisplayRows=6;
myDisplayBox.RowHeight=20;
myDisplayBox.InitBox();
myDisplayBox.addListItem();
myDisplayBox.setItemValue("WholeName","Telsim, Inc.");
myDisplayBox.setItemValue("Phone","1-813-908-1660");
myDisplayBox.setItemValue("Email","<a href='mailto:tfreriks@telsim.com'><u><b>tfreriks@telsim.com</b></u></font>");

Author

Telsim, Inc.