Previous Book Contents Book Index Next

Inside Macintosh: AppleScript Language Guide / Part 2 - AppleScript Language Reference
Chapter 5 - Objects and References


Reference Forms

A reference form is the syntax, or rule, for writing a phrase that identifies an object or group of objects. For example, the Index reference form allows you to identify an object by its number, as in

word 5 of paragraph 10
AppleScript includes other reference forms for identifying objects in applications. Table 5-1 summarizes the reference forms you can use to identify objects. Each section that follows includes a brief explanation of the reference form, a syntax summary, and examples of how to use the reference form to specify application objects. The Filter reference form is described in more detail in "Using the Filter Reference Form," which begins on page 140.
Reference forms
Reference formPurpose
Arbitrary ElementSpecifies an arbitrary object in a container
Every ElementSpecifies every object of a particular class in a container
FilterSpecifies every object in a particular container that matches conditions defined in a Boolean expression
IDSpecifies an object by its ID property
IndexSpecifies the position of an object with respect to the beginning or end of a container
Middle ElementSpecifies the middle object in a container
NameSpecifies an object by its Name property
PropertySpecifies a property of an application object, a record,
a script object, or a date
RangeSpecifies a series of objects
RelativeSpecifies the position of an object in relation to
another object


Previous Book Contents Book Index Next

© Apple Computer, Inc.
13 JUL 1996