ParentRow
Contenuti
[
Nascondere
]Cell.ParentRow property
Restituisce la riga padre della cella.
public Row ParentRow { get; }
Esempi
Mostra come apparecchiare la tavola in modo che tutti siano sulla stessa lunghezza d’onda.
Document doc = new Document(MyDir + "Table spanning two pages.docx");
Table table = doc.FirstSection.Body.Tables[0];
// Abilitazione di KeepWithNext per ogni paragrafo nella tabella eccetto per
// gli ultimi nell'ultima riga impediranno che la tabella venga suddivisa su più pagine.
foreach (Cell cell in table.GetChildNodes(NodeType.Cell, true))
foreach (Paragraph para in cell.Paragraphs)
{
Assert.True(para.IsInCell);
if (!(cell.ParentRow.IsLastRow && para.IsEndOfCell))
para.ParagraphFormat.KeepWithNext = true;
}
doc.Save(ArtifactsDir + "Table.KeepTableTogether.docx");
Guarda anche
- class Row
- class Cell
- spazio dei nomi Aspose.Words.Tables
- assemblea Aspose.Words