开发者

How to Resize Cells in WPF Grid

After constructing a Grid and adding Rows and Columns to it,开发者_开发问答 how can modify the dimension of each Cell. I am not able to locate any property that would help me to achieve this.

As additional note, I am adding TextBlocks to each of the cell.


You can change the column width and row height within your ColumnDefinition and RowDefinition tags, or if you wish to have the cells in a less uniform arrangement you can set the ColumnSpan (might be ColSpan, it's been a while!) and RowSpan properties of each cell to create cells that span more than one row or column.


Do you want modify cells dimensions at runtime? If yes take a look at GridSplitter.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜