Adobe InDesign CS5 Server (7.0) Object Model JS: DocumentPresets

InDesign Server CS5

Class

DocumentPresets

 A collection of document presets.

QuickLinks

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

Properties

PropertyTypeAccessDescription
lengthnumber readonlyThe number of objects in the collection.

Methods

Instances

DocumentPreset [] (index: number)
Returns the DocumentPreset with the specified index.

ParameterTypeDescription
indexnumberThe index.

DocumentPreset add ([withProperties: Object])
Creates a new DocumentPreset.

ParameterTypeDescription
withPropertiesObjectInitial values for properties of the new DocumentPreset (Optional)

DocumentPreset anyItem ()
Returns any DocumentPreset in the collection.

number count ()
Displays the number of elements in the DocumentPreset.

Array of DocumentPreset everyItem ()
Returns every DocumentPreset in the collection.

DocumentPreset firstItem ()
Returns the first DocumentPreset in the collection.

DocumentPreset item (index: varies)
Returns the DocumentPreset with the specified index or name.

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

DocumentPreset itemByID (id: number)
Returns the DocumentPreset with the specified ID.

ParameterTypeDescription
idnumberThe ID.

DocumentPreset itemByName (name: string)
Returns the DocumentPreset with the specified name.

ParameterTypeDescription
namestringThe name.

Array of DocumentPreset itemByRange (from: varies, to: varies)
Returns the DocumentPresets within the specified range.

ParameterTypeDescription
fromDocumentPreset
Long Integer
String
The DocumentPreset, index, or name at the beginning of the range. Can accept: DocumentPreset, Long Integer or String.
toDocumentPreset
Long Integer
String
The DocumentPreset, index, or name at the end of the range. Can accept: DocumentPreset, Long Integer or String.

DocumentPreset lastItem ()
Returns the last DocumentPreset in the collection.

DocumentPreset middleItem ()
Returns the middle DocumentPreset in the collection.

DocumentPreset nextItem (obj: DocumentPreset)
Returns the DocumentPreset whose index follows the specified DocumentPreset in the collection.

ParameterTypeDescription
objDocumentPresetThe DocumentPreset whose index comes before the desired DocumentPreset.

DocumentPreset previousItem (obj: DocumentPreset)
Returns the DocumentPreset with the index previous to the specified index.

ParameterTypeDescription
objDocumentPresetThe index of the DocumentPreset that follows the desired DocumentPreset.

string toSource ()
Generates a string which, if executed, will return the DocumentPreset.

Element of

Application.documentPresets

Jongware, 23-Mar-2011 v3.0.3dContents :: Index