CHAPTER 3
Finder Commands
110 Command Definitions
EXAMPLE
This script copies two files and places them in a folder on another disk:
tell application "Finder"
copy {file "Release Notes" of disk "My World", ¬
file "Report" of disk "My World"} to folder "Backups" of ¬
startup disk
end tell
Count 3
The Count command counts the number of elements of a particular class in a
container. The Finder version of the Count command is similar to the standard
application command described in the AppleScript Language Guide, except that
the Finder’s Count command always returns a single integer.
SYNTAX
count [ each | every ] className [ ( in | of ) referenceToContainer ]
number of className [ ( in | of ) referenceToContainer ]
PARAMETERS
className The class name of the elements to be counted. If you use the
term each or every, you can use only the singular form of
the class name. The kinds of elements that Finder objects can
contain are listed in the object class definitions for each class
in Chapter 2, “Finder Objects.” You must specify a class name
or the command won’t work.
Class: Class identifier
Comments to this Manuals