Back to Devexpress

TableCell.VerticalAlignment Property

officefileapi-devexpress-dot-xtrarichedit-dot-api-dot-native-dot-tablecell-9830644d.md

latest5.8 KB
Original Source

TableCell.VerticalAlignment Property

Gets or sets the vertical justification of content inside a table cell.

Namespace : DevExpress.XtraRichEdit.API.Native

Assembly : DevExpress.RichEdit.v25.2.Core.dll

NuGet Package : DevExpress.RichEdit.Core

Declaration

csharp
TableCellVerticalAlignment VerticalAlignment { get; set; }
vb
Property VerticalAlignment As TableCellVerticalAlignment

Property Value

TypeDescription
TableCellVerticalAlignment

A TableCellVerticalAlignment enumeration value.

|

Available values:

NameDescription
Top

The content is aligned to the top of a cell.

| | Center |

The content is centered across the height of a cell.

| | Bottom |

The content is aligned to the bottom of a cell.

|

The following code snippets (auto-collected from DevExpress Examples) contain references to the VerticalAlignment property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

winforms-richedit-tables-simple-example/CS/TablesSimpleExample/Form1.cs#L136

csharp
document.EndUpdateParagraphs(alignment);
table[0, 1].VerticalAlignment = TableCellVerticalAlignment.Center;

word-document-api-table-examples/CS/Program.cs#L118

csharp
document.EndUpdateParagraphs(alignment);
table[0, 1].VerticalAlignment = TableCellVerticalAlignment.Center;

winforms-richedit-document-api/CS/RichEditAPISample/CodeExamples/Table.cs#L196

csharp
row[2].BackgroundColor = System.Drawing.Color.LightCyan;
    row[2].VerticalAlignment = TableCellVerticalAlignment.Center;
}

wpf-richedit-document-api/CS/DXRichEditControlAPISample/CodeExamples/TableActions.cs#L164

csharp
row[2].BackgroundColor = System.Drawing.Color.LightCyan;
    row[2].VerticalAlignment = TableCellVerticalAlignment.Center;
}

word-document-api-examples/CS/CodeExamples/TablesActions.cs#L271

csharp
row[2].BackgroundColor = System.Drawing.Color.LightCyan;
    row[2].VerticalAlignment = TableCellVerticalAlignment.Center;
}

winforms-richedit-tables-simple-example/VB/TablesSimpleExample/Form1.vb#L112

vb
document.EndUpdateParagraphs(alignment)
table(0, 1).VerticalAlignment = TableCellVerticalAlignment.Center
' Apply formatting to the header cells

word-document-api-table-examples/VB/Program.vb#L94

vb
document.EndUpdateParagraphs(alignment)
table(0, 1).VerticalAlignment = TableCellVerticalAlignment.Center
'Apply formatting to the header cells

winforms-richedit-document-api/VB/RichEditAPISample/CodeExamples/Table.vb#L174

vb
row(CInt((2))).BackgroundColor = System.Drawing.Color.LightCyan
    row(CInt((2))).VerticalAlignment = DevExpress.XtraRichEdit.API.Native.TableCellVerticalAlignment.Center
End Sub

wpf-richedit-document-api/VB/DXRichEditControlAPISample/CodeExamples/TableActions.vb#L146

vb
row(2).BackgroundColor = System.Drawing.Color.LightCyan
    row(2).VerticalAlignment = TableCellVerticalAlignment.Center
End Sub

word-document-api-examples/VB/CodeExamples/TablesActions.vb#L233

vb
row(2).BackgroundColor = Color.LightCyan
    row(2).VerticalAlignment = TableCellVerticalAlignment.Center
End If

See Also

TableCell Interface

TableCell Members

DevExpress.XtraRichEdit.API.Native Namespace