Specifies vertical justification of text on each page.
[Visual Basic]
Public Enum PageVerticalAlignment
[C#]public enum PageVerticalAlignment
Remarks
Example
Shows how to insert sections using DocumentBuilder, specify page setup for a section and reset page setup to defaults.
[C#]
DocumentBuilder builder = new DocumentBuilder();
// Modify the first section in the document.
builder.PageSetup.Orientation = Orientation.Landscape;
builder.PageSetup.VerticalAlignment = PageVerticalAlignment.Center;
builder.Writeln("Section 1, landscape oriented and text vertically centered.");
// Start a new section and reset its formatting to defaults.
builder.InsertBreak(BreakType.SectionBreakNewPage);
builder.PageSetup.ClearFormatting();
builder.Writeln("Section 2, back to default Letter paper size, portrait orientation and top alignment.");
builder.Document.Save(MyDir + "PageSetup.ClearFormatting Out.doc");[Visual Basic]
Dim builder As DocumentBuilder = New DocumentBuilder()
' Modify the first section in the document.
builder.PageSetup.Orientation = Orientation.Landscape
builder.PageSetup.VerticalAlignment = PageVerticalAlignment.Center
builder.Writeln("Section 1, landscape oriented and text vertically centered.")
' Start a new section and reset its formatting to defaults.
builder.InsertBreak(BreakType.SectionBreakNewPage)
builder.PageSetup.ClearFormatting()
builder.Writeln("Section 2, back to default Letter paper size, portrait orientation and top alignment.")
builder.Document.Save(MyDir & "PageSetup.ClearFormatting Out.doc")Members
| Member Name | Description | Value |
| Bottom | Text is aligned at the bottom of the page. | 3 |
| Center | Text is aligned in the middle of the page. | 1 |
| Justify | Text is spread to fill the page. | 2 |
| Top | Text is aligned at the top of the page. | 0 |
Requirements
Namespace: Aspose.Words
Assembly: Aspose.Words (in Aspose.Words.dll)
See Also
Aspose.Words Namespace | PageSetup