Language Guide
CHAPTER 3
Values
58 Value Class Definitions
NOTES
To specify a particular property of a record, you give its name. For example, if
you assign the record to a variable, as in
copy { name:"Mitchell", height:70.5, weight:165 } to writer
you can then get the value of the Name property with the expression
name of writer
A property of a record can contain a value of any class. You can change the
class of a property simply by assigning a value belonging to another class.
After you define a record, you cannot add additional properties to it. You can,
however, concatenate records. For more information, see “Concatenation” on
page 177.
Reference 3
A value of class Reference is a reference to an object. You can create a value of
class Reference by using the A Reference To operator. In addition, applications
can return references in response to commands.
A value of class Reference is different from the value of the object to which a
reference refers. For example, the reference
word 1 of front window of app "Scriptable Text Editor"
--result: a string
refers to a word object, whose value is a string, such as "Today". But a value
of class Reference created with the A Reference To operator is a structure
within AppleScript that refers (or points) to a specific object.
a reference to word 1 of front window of app ¬
"Scriptable Text Editor"
--result: word 1 of window 1 of application ¬
"Scriptable Text Editor"