Previous Book Contents Book Index Next

Inside Macintosh: AppleScript Language Guide / Part 2 - AppleScript Language Reference

Chapter 4 - Commands

A command is a word or series of words used in AppleScript statements to request an action. Every command is directed at a target, which is the object that responds to the command. The target is usually an application object,
but it can also be a script object or a user-defined subroutine or value in the current script.

Not all commands can be used with all types of targets. When you use a command to request an action, you must choose a command that works with the target you want to manipulate. You must also be sure to specify the target correctly. Several factors, including the direct parameter you provide with a command and whether or not the command is included in a Tell statement, can determine the target of a command.

This chapter begins by describing types of commands and targets of commands. It summarizes which types of commands work with which types of targets. Next, it describes the details of using commands and command definitions, including specifying parameters and using results of commands. The chapter ends with definitions of standard commands.

Chapter Contents
Types of Commands
Application Commands
AppleScript Commands
Scripting Addition Commands
User-Defined Commands
Using Command Definitions
Using Parameters
Parameters That Specify Locations
Coercion of Parameters
Raw Data in Parameters
Using Results
Double Angle Brackets in Results and Scripts
Command Definitions

Previous Book Contents Book Index Next

© Apple Computer, Inc.
13 JUL 1996