Interactive ElementsFormFields

A collection of form fields.

Instance Properties

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

Methods

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