TextRange.InsertPageNumber Method
Publisher Developer Reference |
Returns a TextRange object that represents a page number field in a publication.
Syntax
expression.InsertPageNumber(Type)
expression A variable that represents a TextRange object.
Parameters
Name | Required/Optional | Data Type | Description |
---|---|---|---|
Type | Optional | PbPageNumberType | Specifies whether the page number is the current page number or the next or previous page number of a linked text box. |
Return Value
TextRange
Remarks
Type can be one of these PbPageNumberType constants.
Constant | Description |
---|---|
pbPageNumberCurrent | The default. |
pbPageNumberNextInStory | Inserts the page number of the next linked text box. |
pbPageNumberPreviousInStory | Inserts the page number of the previous linked text box. |
Example
This example inserts a page number field in a shape on the master page so that the current page number appears at the top of each page.
Visual Basic for Applications |
---|
|
See Also