sOption | (String) Selected option of the table column for which we want to set the value.
WidthMode - The mode of changing the table column width.
const (default) - The column width is constant, it does not change with the size of the Body area of the table. However, the size of the column can be changed by dragging the mouse or by double-clicking on the right edge of the column in the table header.
resize - The width of the column will change as the size of the Body area of the table changes according to the following conditions:
- If the sum of all set column widths is less than the width of the Body area of the table (i.e. there is still space after the last column in the table), then the column width is increased so that the columns fill the entire Body area of the table.
If multiple columns have set WidthMode=resize, then the widths of the individual columns are increased in proportion to their base set widths. - If the sum of all set column widths is bigger than the width of the Body area of the table (i.e. the columns do not fit in the table and a horizontal scrollbar is shown), then the column width will not be increased and will remain at its base setting. |
---|---|
vValue | (Variant) The value for the selected table column option.
This value depends on the selected table column option. See description of each table column option. |
nColArea | (Long) Detecting the area of the table (see Areas in the table).
1 - Main area of the table
2 - Left area of the table |
iCol | (Long) Column index (zero-based index, -1 = the last column) |
nCount | [optional] (Long) Number of columns for which the value of the selected column option will be set.
- If not set, then the value is 1.
- If iCol=-1 (i.e. the last column) then it is the number of last columns (otherwise it is a number of columns since index iCol).
- If nCount=-1 then it is the number of columns from the index iCol to the last column.
Note: It is not possible to enter iCol=-1 and simultaneously nCount=-1. |
oTable.SetColOption("WidthMode", "resize", 1, 5, 1);