BasicsBackgroundTask

background task

Instance Properties

Name Description Access
alerts The alerts encountered while running this task object. Can return: Array of Array of 2 TaskAlertType enumerators or Strings. read-only
documentName string The document name on which this task operates. read-only
eventListeners EventListeners A collection of event listeners. read-only
events Events A collection of events. read-only
id number The unique ID of the BackgroundTask. read-only
index number The index of the BackgroundTask within its containing object. read-only
isValid bool Returns true if the object specifier resolves to valid objects. read-only
name string The name of the BackgroundTask. read-only
parent Application The parent of the BackgroundTask (a Application). read-only
percentDone number Progress information for this task. read-only
properties Object A property that allows setting of several properties at the same time. read-write
status TaskState The current status of this task object. read-only

Methods

addEventListener(
eventType, handler ​[, captures])
 → EventListener
queryProperty(
name)
removeEventListener(
eventType, handler ​[, captures])
 → bool
toSource(
)
 → string
toSpecifier(
)
 → string
addEventListener(
eventType, handler ​[, captures=false])
 → EventListener
Adds an event listener.
eventType string The event type.
handler The event handler. Can accept: File or JavaScript Function.
captures bool This parameter is obsolete. (Optional)
cancelTask(
)
Cancels the specified background task.
getElements(
)
 → BackgroundTask
Resolves the object specifier, creating an array of object references.
queryProperty(
name)
Queries for a particular property in the task metadata.
name string The task property being queried
removeEventListener(
eventType, handler ​[, captures=false])
 → bool
Removes the event listener.
eventType string The registered event type.
handler The registered event handler. Can accept: File or JavaScript Function.
captures bool This parameter is obsolete. (Optional)
toSource(
)
 → string
Generates a string which, if executed, will return the BackgroundTask.
toSpecifier(
)
 → string
Retrieves the object specifier.
waitForTask(
)
 → TaskState
Waits for the task to finish.