Adobe 65010248 Scripting Guide - Page 26
Quitting Illustrator, AppleScript, JavaScript, Working with objects
UPC - 883919156484
View all Adobe 65010248 manuals
Add to My Manuals
Save this manual to your list of manuals |
Page 26 highlights
CHAPTER 3: Scripting Illustrator Working with objects 26 ➤ Use the New operator if you added a reference to the Illustrator type library to the project. For example, the following line creates a new reference to the Application object: Set appRef = New Illustrator.Application Quitting Illustrator AppleScript Use the quit command: tell application "Adobe Illustrator" quit end tell JavaScript Use the app.quit() method: app.quit() VBScript Use the Application object's Quit method: Set appRef = CreateObject("Illustrator.Application") appRef.Quit Working with objects Getting the frontmost document or layer To refer to the selected document, use the application object's current document property in AppleScript or the active document property in JavaScript or VBScript. Similarly, you can use the document object's current layer or active layer property to refer to the selected layer. There are other types of "active" or "current" object properties, like active dataset or active view. For details, see the Adobe Illustrator CS4 Scripting Reference for your language. Creating new objects Several objects (besides the application object itself ) cannot be obtained from containers or parent objects. Your script must create these objects directly.