PageReferences

A collection of index page references.

Methods:

[], add, anyItem, count, everyItem, firstItem, item, itemByID, itemByName, itemByRange, lastItem, middleItem, nextItem, previousItem, toSource

Property Listing

Property

Type

Access

Description

length

Number

readonly

The number of objects in the collection.

Method Listing

PageReference [] (index:Number)

Returns the PageReference with the specified index.

Parameter

Type

Description

index

Number

The index.

PageReference add (source:Text, [pageReferenceType:PageReferenceType=PageReferenceType], pageReferenceLimit:Varies ParagraphStyle LongInteger, pageNumberStyleOverride:CharacterStyle, withProperties:Object)

Creates a new page reference.

Parameter

Type

Description

source

Text

The text or insertion point to which the page reference points.

pageReferenceType

PageReferenceType

PageReferenceType.CURRENT_PAGE

PageReferenceType.FOR_NEXT_N_PAGES

PageReferenceType.FOR_NEXT_N_PARAGRAPHS

PageReferenceType.SUPPRESS_PAGE_NUMBERS

PageReferenceType.TO_END_OF_DOCUMENT

PageReferenceType.TO_END_OF_SECTION

PageReferenceType.TO_END_OF_STORY

PageReferenceType.TO_NEXT_STYLE_CHANGE

PageReferenceType.TO_NEXT_USE_OF_STYLE

The page number for an index page reference or the last page in an index page reference page range. (Optional)

(default: PageReferenceType.CURRENT_PAGE)

pageReferenceLimit

ParagraphStyle

LongInteger

The paragraph style or number of paragraphs or pages that defines the last page in a page range. Valid only when page reference type specifies the next use of a paragraph style or a number of paragraphs or pages. . Can accept: ParagraphStyle or Long Integer. (Optional)

pageNumberStyleOverride

CharacterStyle

The style override for the page number. (Optional)

withProperties

Object

Initial values for properties of the new PageReference (Optional)

PageReference anyItem ()

Returns any PageReference in the collection.

Number count ()

Displays the number of elements in the PageReference.

PageReference everyItem ()

Returns every PageReference in the collection.

PageReference firstItem ()

Returns the first PageReference in the collection.

PageReference item (index:Varies LongInteger String)

Returns the PageReference with the specified index or name.

Parameter

Type

Description

index

LongInteger

String

The index or name. Can accept: Long Integer or String.

PageReference itemByID (id:Number)

Returns the PageReference with the specified ID.

Parameter

Type

Description

id

Number

The ID.

PageReference itemByName (name:String)

Returns the PageReference with the specified name.

Parameter

Type

Description

name

String

The name.

PageReference itemByRange (from:Varies LongInteger PageReference String, to:Varies LongInteger PageReference String)

Returns the PageReferences within the specified range.

Parameter

Type

Description

from

LongInteger

PageReference

String

The PageReference, index, or name at the beginning of the range. Can accept: PageReference, Long Integer or String.

to

LongInteger

PageReference

String

The PageReference, index, or name at the end of the range. Can accept: PageReference, Long Integer or String.

PageReference lastItem ()

Returns the last PageReference in the collection.

PageReference middleItem ()

Returns the middle PageReference in the collection.

PageReference nextItem (obj:PageReference)

Returns the PageReference whose index follows the specified PageReference in the collection.

Parameter

Type

Description

obj

PageReference

The PageReference whose index comes before the desired PageReference.

PageReference previousItem (obj:PageReference)

Returns the PageReference with the index previous to the specified index.

Parameter

Type

Description

obj

PageReference

The index of the PageReference that follows the desired PageReference.

String toSource ()

Generates a string which, if executed, will return the PageReference.

Object of

Topic.pageReferences