List Column - ColumnUnits Property

Specifies whether the column is a specific width or uses a proportion of the available space (See ColumnWidth)

Member of List Column (PRIM_LIST.Column)

Data Type - Enumeration

Details

The ColumnUnits property defines how the ColumnWidth is evaluated.

Allowed Values

Enum ValueDescription
PixelsAllocate the number of pixels as specified in the ColumnWidth property
ProportionAllocate as a proportion of the remaining space after all Pixel columns have been evaulated.

Example

This example shows a typical scenario of several columns that are fixed in width with the last column using the remaining space.
 
The fourth column uses a proportion of the space available. As it is the only proportional column, it takes all the space.
 
As the first 3 are using the default of 150 pixels and the list itself is 1000 wide, the last column will fill the space, initially taking 550 pixels.
Define_Com Class(#PRIM_LIST) Name(#List) Displayposition(1) Height(456) Left(0) Parent(#COM_OWNER) Tabposition(1) Top(0) Width(1000)
Define_Com Class(#PRIM_LIST.String) Name(#ListColumn1) Displayposition(1) Parent(#List)
Define_Com Class(#PRIM_LIST.String) Name(#ListColumn2) Displayposition(2) Parent(#List)
Define_Com Class(#PRIM_LIST.String) Name(#ListColumn3) Displayposition(3) Parent(#List)
Define_Com Class(#PRIM_LIST.String) Name(#ListColumn4) Displayposition(4) Parent(#List) Columnunits(Proportion)
This second example has 2 fixed columns flanked by 2 proportional columns.
 
The fixed columns occupy a total of 300 pixels of the 900 pixels available. The remaining 600 are split between the two proportional columns in the ratio 2:1. This results in column 1 being 200 wide and column 2 being 400 wide.
Define_Com Class(#PRIM_LIST) Name(#List) Displayposition(1) Height(456) Left(0) Parent(#COM_OWNER) Tabposition(1) Top(0) Width(900)
Define_Com Class(#PRIM_LIST.String) Name(#ListColumn1) Displayposition(1) Parent(#List) Columnunits(Proportion) Cellwidth(0) Columnwidth(1.0)
Define_Com Class(#PRIM_LIST.String) Name(#ListColumn2) Displayposition(2) Parent(#List) Columnwidth(200)
Define_Com Class(#PRIM_LIST.String) Name(#ListColumn3) Displayposition(3) Parent(#List) Columnwidth(100)
Define_Com Class(#PRIM_LIST.String) Name(#ListColumn4) Displayposition(4) Parent(#List) Columnunits(Proportion) Columnwidth(2.0)
If a third proportional column with a width of 3 were to be introduced, the proportional columns would have a combined total width of 6 parts and would still use the available 600 pixels.
 
This would result in widths of 300, 200 and 100.

See also

All Component Classes

Technical Reference

Febuary 18 V14SP2