InDesign2026
API 21.5.1.73
Object

XMLImportPreference

XML import preferences.

Preference XMLImportPreference
Hierarchy

Application | Document

XMLImportPreference

Properties

NameType AccessDescription
Boolean read/write If true, transforms the XML using an XSLT file.
Boolean read/write If true, creates a link to the imported XML file. If false, embeds the file.
EventListeners<EventListener> readonly A collection of event listeners.
Events<Event> readonly A collection of events.
Boolean read/write If true, ignores elements that do not match the existing structure. Note: Valid only when import style is merge.
Boolean read/write If true, leaves existing content in place if the matching XML content contains only whitespace characters such as a carriage return or a tab character. Note: Valid only when import style is merge.
Boolean = true read/write If true, imports CALS tables as InDesign tables.
XMLImportStyles
read/write The style of incorporating imported XML content into the document.
Boolean read/write If true, imports text into tables if tags match placeholder tables and their cells. Note: Valid only when import style is merge.
Boolean read/write If true, imports into the selected XML element. If false, imports at the root element.
Boolean readonly Returns true if the object specifier resolves to valid objects.
Application | Document readonly The parent of the XMLImportPreference (a Application or Document).
Object read/write A property that allows setting of several properties at the same time.
Boolean read/write If true, deletes existing elements or placeholders in the document that do not have matches in the XML file. Note: Valid only when import style is merge.
Boolean read/write If true, repeating text elements inherit the formatting applied to placeholder text. Note: Valid only when import style is merge.
File | XMLTransformFile
read/write The name of the XSLT file. Note: Valid when allow transform is true. Can return: File or XMLTransformFile enumerator.
Array[] | String[] read/write Stylesheet parameters as a list of name/value pairs in the format [[name, value], [name, value], ...]. Can return: Ordered array containing name:String, value:String.

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.
XMLImportPreference[]

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

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.
String

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

String

Retrieves the object specifier.

Object of 5

Properties elsewhere that hold a XMLImportPreference.

Return 1

Methods that return a XMLImportPreference.