6

I've created a table with 2 columns. In the second cell of the first row I want to insert another table that have only one cell. The problem is that I can't set the height of the second table. It stretches more than the content height. Its height is equal with the cell height where it was added.

Brian Tompsett - 汤莱恩
  • 5,753
  • 72
  • 57
  • 129
Emanuel
  • 6,622
  • 20
  • 58
  • 78

2 Answers2

10

Table's height depends on its parent container. So you should set height of the parent cell. You can do this in two ways:

cell.MinimumHeight = 50f;

or

 cell.FixedHeight = 70f;
algreat
  • 8,592
  • 5
  • 41
  • 54
3

The height of the table cannot be set, the height of the table is determined by the height of its cells (you can set the height-property of a cell). You could add an empty cell to the second table if you want to stretch this table.

Robin van der Knaap
  • 4,060
  • 2
  • 33
  • 48