OfficeIMO

API Reference

Class

WordPageNumber

Namespace OfficeIMO.Word
Assembly OfficeIMO.Word

Represents a page-numbering building block.

Inheritance

  • Object
  • WordPageNumber

Constructors

WordPageNumber 2 overloads
public WordPageNumber(WordDocument wordDocument, WordFooter wordFooter, WordPageNumberStyle wordPageNumberStyle) #

Initializes a new instance of WordPageNumber and appends it to the specified header.

Parameters

wordDocument OfficeIMO.Word.WordDocument requiredposition: 0
Document where the page number will be inserted.
wordHeader OfficeIMO.Word.WordHeader requiredposition: 1
Header that will contain the page number.
wordPageNumberStyle OfficeIMO.Word.WordPageNumberStyle requiredposition: 2
Style applied to the page number.
WordPageNumber(OfficeIMO.Word.WordDocument wordDocument, OfficeIMO.Word.WordFooter wordFooter, OfficeIMO.Word.WordPageNumberStyle wordPageNumberStyle) #

Initializes a new instance of WordPageNumber and appends it to the specified footer.

Parameters

wordDocument OfficeIMO.Word.WordDocument required
Document where the page number will be inserted.
wordFooter OfficeIMO.Word.WordFooter required
Footer that will contain the page number.
wordPageNumberStyle OfficeIMO.Word.WordPageNumberStyle required
Style applied to the page number.

Methods

public WordParagraph AppendText(String text) #
Returns: WordParagraph

Appends text to the last paragraph of the page number.

Parameters

text System.String requiredposition: 0
Text to append.

Returns

The paragraph that received the text.

Properties

public Nullable<JustificationValues> ParagraphAlignment { get; set; } #

Gets or sets the alignment of the page-number paragraph.

public WordParagraph Paragraph { get; } #

Gets the primary paragraph containing the page number field.

public IReadOnlyList<WordParagraph> Paragraphs { get; } #

Gets all paragraphs that make up the page number content.

public WordField Field { get; } #

Gets the underlying field representing the page number.

public Nullable<Int32> Number { get; } #

Gets the numeric value from the field text if available.

public String CustomFormat { get; set; } #

Gets or sets the custom format of the page number field.