LayoutPages

A collection of pages.

Instance Properties

Name Description Access
length number The number of objects in the collection. read-only

Methods

add(
[at], reference ​[, withProperties])
 → Page
anyItem(
)
 → Page
count(
)
 → number
everyItem(
)
 → Page
firstItem(
)
 → Page
item(
index)
 → Page
itemByID(
id)
 → Page
itemByName(
name)
 → Page
itemByRange(
from, to)
 → Page
lastItem(
)
 → Page
middleItem(
)
 → Page
nextItem(
obj)
 → Page
previousItem(
obj)
 → Page
toSource(
)
 → string
add(
[at=LocationOptions.UNKNOWN], reference ​[, withProperties])
 → Page
Creates a new page.
at LocationOptions The location of the new page relative to the reference object or within the document or spread. (Optional)
reference The reference object. Note: Required when the at parameter value specifies before or after. Can accept: Page, Spread, MasterSpread or Document. (Optional)
withProperties Object Initial values for properties of the new Page (Optional)
anyItem(
)
 → Page
Returns any Page in the collection.
count(
)
 → number
Displays the number of elements in the Page.
everyItem(
)
 → Page
Returns every Page in the collection.
firstItem(
)
 → Page
Returns the first Page in the collection.
item(
index)
 → Page
Returns the Page with the specified index or name.
index The index or name. Can accept: Long Integer or String.
itemByID(
id)
 → Page
Returns the Page with the specified ID.
id number The ID.
itemByName(
name)
 → Page
Returns the Page with the specified name.
name string The name.
itemByRange(
from, to)
 → Page
Returns the Pages within the specified range.
from The Page, index, or name at the beginning of the range. Can accept: Page, Long Integer or String.
to The Page, index, or name at the end of the range. Can accept: Page, Long Integer or String.
lastItem(
)
 → Page
Returns the last Page in the collection.
middleItem(
)
 → Page
Returns the middle Page in the collection.
nextItem(
obj)
 → Page
Returns the Page whose index follows the specified Page in the collection.
obj Page The Page whose index comes before the desired Page.
previousItem(
obj)
 → Page
Returns the Page with the index previous to the specified index.
obj Page The index of the Page that follows the desired Page.
toSource(
)
 → string
Generates a string which, if executed, will return the Page.