InDesign2026
API 21.5.1.73
Object

XMLInstruction

An XML processing instruction.

XMLItem XMLInstruction
Hierarchy

Document | XMLElement

XMLInstruction

Properties

NameType AccessDescription
String read/write A value that tells the application reading the exported XML file what to do with the processing instruction.
EventListeners<EventListener> readonly A collection of event listeners.
Events<Event> readonly A collection of events.
Number readonly The unique ID of the XMLInstruction.
Number readonly The index of the XMLInstruction within its containing object.
Boolean readonly Returns true if the object specifier resolves to valid objects.
Document | XMLElement readonly The parent of the XMLInstruction (a Document or XMLElement).
Object read/write A property that allows setting of several properties at the same time.
InsertionPoint readonly The insertion point before the table in the story containing the table.
String read/write A name that identifies the processing instruction to an application reading the exported XML file.

Methods

EventListener

Adds an event listener.

eventType String The event type.
handler File | JavaScriptFunction The event handler. Can accept: File or JavaScript Function.
captures? Boolean This parameter is obsolete.
XMLInstruction[]

Resolves the object specifier, creating an array of object references.

XMLInstruction

Moves the element to the specified location.

to LocationOptions The location in relation to the reference object or within the containing object.
reference? XMLItem | Text The reference object. Note: Required when the to parameter specifies before or after. . Can accept: XMLItem or Text.
void

Deletes the XMLInstruction.

Boolean

Removes the event listener.

eventType String The registered event type.
handler File | JavaScriptFunction The registered event handler. Can accept: File or JavaScript Function.
captures? Boolean This parameter is obsolete.
void

Selects the object.

existingSelection? SelectionOptions The selection status of the XMLInstruction in relation to previously selected objects.
String

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

String

Retrieves the object specifier.

Object of 3

Properties elsewhere that hold a XMLInstruction.

Parameter of 3

Method parameters that accept a XMLInstruction.

Return 15

Methods that return a XMLInstruction.