[]
Specifies the vertical alignment of text within a shape's text frame.
Use this enum with VerticalAnchor to position text at the top, middle, or bottom of the text frame.
public enum VerticalAnchor
Public Enum VerticalAnchor
IShape shape = worksheet.Shapes.AddShape(AutoShapeType.Rectangle, 10, 10, 120, 80);
shape.TextFrame.TextRange.Text = "Hello";
shape.TextFrame.VerticalAnchor = VerticalAnchor.AnchorMiddle;
| Name | Description |
|---|---|
| AnchorBottom | Aligns text to bottom of text frame. |
| AnchorMiddle | Centers text vertically. |
| AnchorTop | Aligns text to top of text frame. |