GridColumn.SetWidthToAuto
method · GridColumn · cAlgo.API
DesktopCLICloud
Sets the grid column width to automatic.
Environment behaviour
CLI — not supported. Never available in the CLI: it is only returned by members that do not work there (Grid.AddColumn, Grid.Columns).
Cloud — not supported. Never available in the cloud: it is only returned by members that do not work there (Grid.AddColumn, Grid.Columns).
Definition
void SetWidthToAuto()
gridColumn.SetWidthToAuto() -> None
Examples
var grid = new Grid(1, 2);
grid.Columns[0].SetWidthToAuto();
grid.AddChild(new TextBlock { Text = "Sized to content" }, 0, 0);
Chart.AddControl(grid);
grid = Grid(1, 2)
grid.Columns[0].SetWidthToAuto()
textBlock = TextBlock()
textBlock.Text = "Sized to content"
grid.AddChild(textBlock, 0, 0)
api.Chart.AddControl(grid)