Hi,
There is no built-in support for grouping. You can specify how many rows should be spanned by a cell by setting its RowSpan property, so you could implement that yourself using this method:
void MergeCells(TableNode table, int column)
{
int startIndex = 0;
while (startIndex < table.Rows.Count)
{
int span = 1;
while (startIndex + span < table.Rows.Count &&
table[column, startIndex].Text == table[column, startIndex + span].Text)
{
span++;
}
if (span > 1)
{
table[column, startIndex].RowSpan = span;
table[column, startIndex].TextFormat.FormatFlags =
StringFormatFlags.DirectionVertical;
}
startIndex += span;
}
}
var t = diagram.Factory.CreateTableNode(10, 10, 30, 100, 3, 20);
t[0, 0].Text = "test 1";
t[0, 1].Text = "test 2";
t[0, 2].Text = "test 2";
t[0, 3].Text = "test 2";
t[0, 4].Text = "test 3";
t[0, 5].Text = "test 4";
t[0, 6].Text = "test 4";
t[0, 7].Text = "test 5";
MergeCells(t, 0);
I hope that helps,
Stoyan