GridPanel.setColumnWidth

Syntax

setColumnWidth (columnNumber, width);

Parameters

columnNumber. Row number.

width. Row width.

Description

The setColumnWidth method sets the width of the table column.

Example

To execute the example, the HTML page must contain GridPanel component named container (see Example of Creating the GridPanel Component). Requires the DIV tags with the "ne1" and "ne1" identifiers. Add to the page value editors used to set width and height of the first table cell:

    var numberH = new PP.Ui.NumberEdit({ ParentNode: document.getElementById("ne1"), Width: 50});

    var numberW = new PP.Ui.NumberEdit({ ParentNode: document.getElementById("ne2"), Width: 50});

    numberH.AfterValueChange.add(function (sender, args) { container.setRowHeight(0, numberH.getValue()) });

    numberW.AfterValueChange.add(function (sender, args) { container.setColumnWidth(0, numberW.getValue()) });

Numeric editors are allocated on the HTML page after an example execution. The width and the height of the first table cell are changing when setting the editor values.

Seebsp;also:

GridPanel