TextVariable

A text variable definition in a document.

Properties

Property Type Access Description
associatedInstances Array of TextVariableInstance readonly Variable instances associated with the TextVariable.
index number readonly The index of the TextVariable within its containing object.
name string r/w The name of the TextVariable.
parent any readonly The parent of the TextVariable (a Application or Document).
properties Object r/w A property that allows setting of several properties at the same time.
variableOptions any readonly The preferences associated with the TextVariable. Can return: PageNumberVariablePreference, ChapterNumberVariablePreference, DateVariablePreference, FileNameVariablePreference, MatchCharacterStylePreference, MatchParagraphStylePreference or CustomTextVariablePreference.
variableType VariableTypes
:
CUSTOM_TEXT_TYPE
FILE_NAME_TYPE
LAST_PAGE_NUMBER_TYPE
CHAPTER_NUMBER_TYPE
OUTPUT_DATE_TYPE
CREATION_DATE_TYPE
MODIFICATION_DATE_TYPE
MATCH_CHARACTER_STYLE_TYPE
MATCH_PARAGRAPH_STYLE_TYPE
r/w The TextVariable type.

Methods

TextVariableconvertToText ()
Convert all variable instances to text

Array of TextVariablegetElements ()
Resolves the object specifier, creating an array of object references.

void remove ()
Deletes the TextVariable.

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

string toSpecifier ()
Retrieves the object specifier.

Element of:

ChapterNumberVariablePreference.parent
CustomTextVariablePreference.parent
DateVariablePreference.parent
FileNameVariablePreference.parent
MatchCharacterStylePreference.parent
MatchParagraphStylePreference.parent
PageNumberVariablePreference.parent
TextVariableInstance.associatedTextVariable

Used in:

TextVariables.previousItem (

obj:
TextVariable )

TextVariables.nextItem (

obj:
TextVariable )

Returned by:

TextVariable TextVariable .convertToText (

)

Array of TextVariable TextVariable .getElements (

)

TextVariable TextVariables.add (
[withProperties:
Object]
)

TextVariable TextVariables.anyItem (

)

Array of TextVariable TextVariables.everyItem (

)

TextVariable TextVariables.firstItem (

)

TextVariable TextVariables.item (
index:
any
)

TextVariable TextVariables.itemByName (
name:
string
)

Array of TextVariable TextVariables.itemByRange (
from:
any, to:
any
)

TextVariable TextVariables.lastItem (

)

TextVariable TextVariables.middleItem (

)

TextVariable TextVariables.nextItem (
obj:
TextVariable
)

TextVariable TextVariables.previousItem (
obj:
TextVariable
)

Leave a Comment

Previous post:

Next post: