Parameters That Specify Locations
Many commands have parameters that specify locations. A location can be either an insertion point or another object. An insertion point is a location where an object can be added. An object, when used as a location parameter,
is an object to be replaced by another object.For example, in the following statement, the
to
parameter specifies the location to which to move the first word. The value of theto
parameter is the referencebefore paragraph 10
, which is an insertion point.
move word 1 to before paragraph 10In the following statement, the value of theto
parameter is an object,word 10
. The Move command replacesword 10
withword 1
.
tell front window of application "Scriptable Text Editor" move word 1 to word 10 end tellPhrases such asbefore paragraph 10
andword 1
are called relative references and index references, respectively. These kinds of references specify locations. For more information about these kinds of references, see "Index" on page 131 and "Relative" on page 139.